Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - Chris

Pages: 1 2 3 4 [5]
61
This bug is reproducible.

Again I am referring to the 13 images I imported using the admin control panel "Check New Images".

From the 4images_images table, image_date = 1022222283
From 4images/details.php, the date displayed is:  05.24.2002 01:38
From Admin CP, "Edit Images", date displayed is:  2002-05-24 06:38:03
From ls -l at a Linux prompt, the file date is:  May 24 01:28

I don't think the date displayed in the Admin>Edit Images is correct.

62
This bug is reproducible.

I used "Check New Images" in the Admin control panel to import 13 new images into an empty category.  My web server is very fast and the first 10 images were processed within the same second.  Therefore, each of these 10 images have the exact same date/time stamp of 2002-05-24 06:38:03.  The remaining three were all processed in the next second.

I then used the Admin control panel to change the image sort method to "Date" by clicking "Settings" then "Image Settings" and selecting "Date" for "Sort images by".   (Control Panel>Settings>Image settings)

When I select the 1st of the 13 thumbnails, I get the details page for it.

HERE IS THE BUG:  

The {next_image_url} in the details page is set to the 11th image!  I cannot use Next and Previous to navigate between all 13 images.  I can only get to the 1st image that was imported and the 1st image that was imported the next second.  The Previous and Next skip images the other images that have the exact same date/time stamp.

For your information:  All 13 thumbnails are displayed in ascending image name order when clicking the category.

63
In version 1.0, I enhanced details.php to return new variables 'next_image2' and 'next_image3'.  This was so I could display the previous and next 3 image thumbnails to the user for navigational purposes.  

I don't know PHP but I am make my living as a programmer.  It was easy enough for me to figure out that this data was already available in the cache.

Under 1.5 beta, this cache seems to have been removed.  I spent a couple hours yesterday trying to figure out how to accomplish the same thing but failed.  

Does anyone know if it's possible to copy and hack these sections of code to get the next 3 images instead of just the next 1 image?

Code: [Select]

details.php
-----------

$order = ($config['image_sort'] == "DESC") ? "DESC" : "ASC";
$condition = ($order == "DESC") ? "<" : ">";
$row = $site_db->query_firstrow("SELECT image_id AS next_image_id
                                 FROM ".IMAGES_TABLE."
                                 WHERE ".$config['image_order']." $condition '".$search_key."' AND cat_id = $cat_id AND image_active = 1
                                 ORDER BY ".$config['image_order']." $order
                                 LIMIT 1");
$next_image_id = (!empty($row['next_image_id'])) ? $row['next_image_id'] : 0;
$next_image_name = REPLACE_EMPTY;
$next_image_url = REPLACE_EMPTY;
$next_image_file = REPLACE_EMPTY;
$next_thumb_file = REPLACE_EMPTY;

...

// Get next and previous image
if (!empty($image_row[$next_image_id])) {
  $next_image_name = stripslashes($image_row[$next_image_id]['image_name']);
  $next_image_url = $site_sess->url(ROOT_PATH."details.php?".URL_IMAGE_ID."=".$next_image_id);
  $next_image_file = (is_remote($image_row[$next_image_id]['image_media_file'])) ? $image_row[$next_image_id]['image_media_file'] : MEDIA_PATH."/".$cat_id."/".$image_row[$next_image_id]['image_media_file'];
  $next_thumb_file = (is_remote($image_row[$next_image_id]['image_thumb_file'])) ? $image_row[$next_image_id]['image_thumb_file'] : THUMB_PATH."/".$cat_id."/".$image_row[$next_image_id]['image_thumb_file'];
}


It's the LIMIT 1 and query_firstrow() I couldn't figure out how to replace (I think)

Here is a screen shot to illustrate what I'm trying to do:


The 2nd and 3rd '190-14' should be '190-15' and '190-16'.

(I only blurred the URL because my site isn't public yet.  Too much work to do before going live.)

64
For your information:

Code: [Select]
Hits: {hits}<br />

The above worked in 1.0 but not in 1.5 beta.

65
I like the user registrations and want to use the admin control panel to inform my users when I post new pictures.  But I also want to respect their privacy and offer an opt-out mechanism.  If this was stored in the user's profile, the admin control panel 'send email' feature could use it to avoid pre-selecting their id in the form.

66
Feedback & Suggestions / Better no right-click script in this post
« on: May 12, 2002, 07:51:33 PM »
The current script included in 1.5 beta doesn't work in Mozilla 1.0 RC2 or Netscape 6.2.2.  It also displays the alert() twice.

Code: [Select]

<SCRIPT LANGUAGE="Javascript">
<!--
// ***********************************************
//  http://www.cgiscript.net/scripts.htm
// ***********************************************
var isNS = (navigator.appName == "Netscape") ? 1 : 0;
var EnableRightClick = 0;
if(isNS)
document.captureEvents(Event.MOUSEDOWN||Event.MOUSEUP);
function mischandler(){
  if(EnableRightClick==1){ return true; }
  else {return false; }
}
function mousehandler(e){
  if(EnableRightClick==1){ return true; }
  var myevent = (isNS) ? e : event;
  var eventbutton = (isNS) ? myevent.which : myevent.button;
  if((eventbutton==2)||(eventbutton==3)) {
    alert('© Copyright {site_name}');
    return false;
  }
}
function keyhandler(e) {
  var myevent = (isNS) ? e : window.event;
  if (myevent.keyCode==96)
    EnableRightClick = 1;
  return;
}
document.oncontextmenu = mischandler;
document.onkeypress = keyhandler;
document.onmousedown = mousehandler;
// document.onmouseup = mousehandler;
//-->
</script>


This script belongs in the header.html template and has been tested in Mozilla, Netscape and IE.  I don't have Opera to try it.

67
If I add a new image using a URL instead of uploading a file, the following code fragment produces broken links:

Code: [Select]

// Get next and previous image
if (!empty($image_row[$next_image_id])) {
  $next_image_name = stripslashes($image_row[$next_image_id]['image_name']);
  $next_image_url = $site_sess->url(ROOT_PATH."details.php?".URL_IMAGE_ID."=".$next_image_id);
  $next_image_file = MEDIA_PATH."/".$cat_id."/".$image_row[$next_image_id]['image_media_file'];
  $next_thumb_file = THUMB_PATH."/".$cat_id."/".$image_row[$next_image_id]['image_thumb_file'];
}

if (!empty($image_row[$prev_image_id])) {
  $prev_image_name = stripslashes($image_row[$prev_image_id]['image_name']);
  $prev_image_url = $site_sess->url(ROOT_PATH."details.php?".URL_IMAGE_ID."=".$prev_image_id);
  $prev_image_file = MEDIA_PATH."/".$cat_id."/".$image_row[$prev_image_id]['image_media_file'];
  $prev_thumb_file = THUMB_PATH."/".$cat_id."/".$image_row[$prev_image_id]['image_thumb_file'];
}


So
Code: [Select]
{next_image_url} results in:
Code: [Select]

<a href="./details.php?image_id=8"><img src="./data/thumbnails/3/http://www.abc123.com/pics/190/tn190-14.jpg" border="1"></a><br />


My suggested solution:

Track whether or not the image is from a URL or an uploaded file in the 4images_images table.  Construct the image and thumbnail paths if it was uploaded otherwise just use the URL.  

BE SURE TO UPDATE THIS TABLE COLUMN IF THE IMAGE IS EDITED AND A URL IS USED TO REPLACE A PREVIOUSLY UPLOADED IMAGE.  (And delete the local image file)  SAME FOR THE REVERSE SITUATION.

I like this approach since it would also allow for relative URLs.  I have found that 1.5 beta currently only supports absolute URLs.

This IS supported:
Code: [Select]
http://www.abc123.com/pics/190/190-12.jpg

This IS NOT supported:
Code: [Select]
/pics/190/190-12.jpg

----------------------------------------------------------------------------------------

Wenn ich ein neues Bild mit einem URL addiere, anstatt, eine Akte zu hochladen, produziert das folgende Codefragment defekte Verbindungen:

Code: [Select]

// Get next and previous image
if (!empty($image_row[$next_image_id])) {
  $next_image_name = stripslashes($image_row[$next_image_id]['image_name']);
  $next_image_url = $site_sess->url(ROOT_PATH."details.php?".URL_IMAGE_ID."=".$next_image_id);
  $next_image_file = MEDIA_PATH."/".$cat_id."/".$image_row[$next_image_id]['image_media_file'];
  $next_thumb_file = THUMB_PATH."/".$cat_id."/".$image_row[$next_image_id]['image_thumb_file'];
}

if (!empty($image_row[$prev_image_id])) {
  $prev_image_name = stripslashes($image_row[$prev_image_id]['image_name']);
  $prev_image_url = $site_sess->url(ROOT_PATH."details.php?".URL_IMAGE_ID."=".$prev_image_id);
  $prev_image_file = MEDIA_PATH."/".$cat_id."/".$image_row[$prev_image_id]['image_media_file'];
  $prev_thumb_file = THUMB_PATH."/".$cat_id."/".$image_row[$prev_image_id]['image_thumb_file'];
}


So
Code: [Select]
{next_image_url} resultate innen:
Code: [Select]

<a href="./details.php?image_id=8"><img src="./data/thumbnails/3/http://www.abc123.com/pics/190/tn190-14.jpg" border="1"></a><br />


Meine vorgeschlagene Lösung: Schiene, ob oder nicht das Bild von einem URL oder von einer Antriebskraft Akte in der îmages_images Tabelle ist. Konstruieren Sie die Bild- und thumbnailwege, wenn es Antriebskraft anders gerader Gebrauch das URL war.

SEIEN Sie SICHER, DIESE TABELLE SPALTE ZU AKTUALISIEREN, WENN Das BILD REDIGIERT WIRD UND Ein URL BENUTZT WIRD, UM Ein VORHER ANTRIEBSKRAFT BILD ZU ERSETZEN. (und löschen Sie die lokale Bildakte), SELBEN FÜR DIE RÜCKCSituation.

Ich mag diese Annäherung, da sie auch relatives URLs zulassen würde. Ich habe gefunden, daß 1,5 Beta z.Z. nur absolutes URLs stützt.

Dieses WIRD gestützt:
Code: [Select]
http://www.abc123.com/pics/190/190-12.jpg

Dieses WIRD NICHT gestützt:
Code: [Select]
/pics/190/190-12.jpg

68
If I add an image using the control panel, the IPTC info is processed and also displayed in the gallery when if I upload the image from my computer.

If I delete and then add the same image again using a URL instead of uploading from my computer, the IPTC info is NOT displayed.

These tests were done using the default templates.

-------------------------------------------------------------------------------------

Wenn ich ein Bild mit der Steuerverkleidung addiere, wird das IPTC Info verarbeitet und angezeigt auch in der Galerie wenn, wenn ich das Bild von meinem Computer hochlade. Wenn ich lösche und dann das gleiche Bild addiere, das wieder ein URL verwendet, anstatt, von meinem Computer zu hochladen, wird das IPTC Info NICHT angezeigt. Diese Tests wurden mit den Rückstellung Schablonen durchgeführt.

69
If I click on "Reset Stats" I get this error message:

Parse error: parse error in /home/www/Chris/4images/admin/stats.php
on line 49

Thank you for a GREAT image gallery!  With 1.5 beta, I decided to purchase a full license $149 USD for my site.  I only know english so I have pasted a german translation below using http://world.altavista.com

----------------------------------------------------------------------

Wenn ich an "zurückgestellten Notfall" ich anklicke, erhalten Sie diese Fehlermeldung: Analysieren Sie Störung: analysieren Sie Störung in/home/www/Chris/îmages/admin/stats.php auf Linie 49

Danke für eine GROSSE Bildgalerie! Mit 1,5 Beta, entschied ich, eine volle Lizenz zu kaufen $149 USD für meinen Aufstellungsort. Ich spreche nur englisch, also habe ich eine deutsche Übersetzung unterhalb des Verwendens von von http://world.altavista.com geklebt

Pages: 1 2 3 4 [5]