Author Topic: i wanna use next_image_url someone help???  (Read 7341 times)

0 Members and 1 Guest are viewing this topic.

Offline ilaslan

  • Newbie
  • *
  • Posts: 44
    • View Profile
i wanna use next_image_url someone help???
« on: August 18, 2010, 07:00:00 PM »
hello . i am new for 4images. i install 1.7.8 .
and change details.html because i want when i click the images go to the next images

Code: [Select]
{if next_image_url}<a href="{next_image_url}">{endif next_image_url}
{image}
{if next_image_url}</a>{endif next_image_url}

but Nothing is being. i examine a bit and always $next_image_url = REPLACE_EMPTY.

i dont understand anything. is it possible? Someone help me

regards

Rembrandt

  • Guest
Re: i wanna use next_image_url someone help???
« Reply #1 on: August 18, 2010, 07:35:27 PM »
Welcome to the Forum!

i want when i click the images go to the next images ...

try this    http://www.4homepages.de/forum/index.php?topic=24167.msg132459#msg132459

mfg Andi

Offline ilaslan

  • Newbie
  • *
  • Posts: 44
    • View Profile
Re: i wanna use next_image_url someone help???
« Reply #2 on: August 18, 2010, 08:49:49 PM »
thanx but still same problem.

i also tried this

http://www.4homepages.de/forum/index.php?topic=11401.0

 picture middle is working because goes to category page. but  right and left is not working. ( left = previous , right = next image)

because
next_image_url is always null
prev_image_url is always null 

i changed details.php to original and next_image_url not null
so problem is this preiew hack mod  http://www.4homepages.de/forum/index.php?topic=7294.msg124362#msg124362
but iwant to use this preiew hack mod because this has 5 pic not only next and previeus...

do you know same preiew hack?

or what is the problem this hack details.php? this hack is good for us but always return $next_image_file = REPLACE_EMPTY

1:
- open details.php
- search:
- öffne details.php
- suche:
Quote
$image_id_cache = array();


- before add:
- davor einfügen:

Quote
/*--- Start MOD: Photo Preview Hack, reworked by KW ------------------------- */
// Start Settings for Thumbs

$thumbsize =  0.5; // Thumb Size in %

// End Settings

$result = $site_db->query($sql);
while($row = $site_db->fetch_array($result)){
    $image_preview[] = $row['image_id'];
    $preview_row[$row['image_id']] = $row;
}
$lastPage = count($image_preview);
$t_template = "";
if($lastPage < 6){
    $start = 0;
    $end = $lastPage -1;
} elseif ($act_key == 0 || $act_key == 1){
    $start = 0;
    $end   = 4;
} elseif ($act_key == $lastPage-1 || $act_key == $lastPage -2){
    $start = $lastPage - 5;
    $end = $lastPage - 1;
} else {
    $start = $act_key -2;
    $end   = $act_key +2;
}
for($i=$start; $i<=$end; $i++){
    if ($preview_row[$image_preview[$i]]['image_id'] == $image_row['image_id']) {
    $t_template .= "<td class=\"preview_box_colored\">\n";
    } else {
    $t_template .= "<td class=\"preview_box\">\n";
    }
    $tag = get_thumbnail_code($preview_row[$image_preview[$i]]['image_media_file'], $preview_row[$image_preview[$i]]['image_thumb_file'], $preview_row[$image_preview[$i]]['image_id'], $cat_id, format_text(trim($preview_row[$image_preview[$i]]['image_name']), 2), $mode, 1);
    $oriWidth = substr($tag, strpos($tag, "width")+7, strpos($tag, "\" height")-strlen($tag));
    $oriHeight = substr($tag, strpos($tag, "height")+8, strpos($tag, " alt")-strlen($tag)-1);
    $tag = str_replace('width="'.$oriWidth.'"', 'width="'.$oriWidth*$thumbsize.'"', $tag);
    $tag = str_replace('height="'.$oriHeight.'"', 'height="'.$oriHeight*$thumbsize.'"', $tag);
    $t_template .= $tag."<br />";
    $t_template .= "<font class=\"smalltext\">".$preview_row[$image_preview[$i]]['image_name']."</font>\n</td>\n";
}
$site_template->register_vars("preview_box", $t_template);
unset($image_preview);
unset($t_template);
/*--- End MOD: Photo Preview Hack, reworked by KW --------------------------- */

Help please. i want to use 5 or 7 pic tumbail below . and also use click big picture and next image

Rembrandt

  • Guest
Re: i wanna use next_image_url someone help???
« Reply #3 on: August 18, 2010, 09:09:36 PM »
please post your question in the mod topic:

Quote
<div style="border:1px solid #7D8568;width:1060px;">
{if prev_image_name}
<span style="float:left;margin:3px;width:70px; height:50px;"><a href="{prev_image_url}"><img src="{prev_thumb_file}" style="width:70px; height:50px;border-style:none;" alt="prev_img"></a></span>
<span style="float:left;margin:3px;">{lang_prev_image}<br>{prev_image_name}</span>
{endif prev_image_name}
{if next_image_name}
<span style="float:right;margin:3px;width:70px; height:50px;"><a href="{next_image_url}"><img src="{next_thumb_file}" style="width:70px; height:50px;border-style:none;" alt="next_img"></a></span>
<span style="float:right;margin:3px;">{lang_next_image}<br>{next_image_name}</span>
{endif next_image_name}
<div style="clear:both"></div>
</div>


http://www.4homepages.de/forum/index.php?topic=7294.msg139683#msg139683
« Last Edit: August 18, 2010, 09:22:03 PM by Rembrandt »

Offline ilaslan

  • Newbie
  • *
  • Posts: 44
    • View Profile
Re: i wanna use next_image_url someone help???
« Reply #4 on: August 18, 2010, 09:57:26 PM »