Member
Member
RogerUsh   2006-04-17, 15:57
#1
I implemented a bit of custom code in the image.php file and now the description does not show. Here is the current code:

`<?php $_current_image = $_zp_current_image; ?>






<div class="thumbs">


[list]

<?php while (next_image()): ?>


[*]

<a>" title="<?=getImageTitle();?>">


<?php printImageThumb(getImageTitle()); ?>

</a>




<?php endwhile; ?>;


[/list]




<?php $_zp_current_image = $_current_image; ?>





">

<?php printDefaultSizedImage(getImageTitle()); ?>




<div class="description">


<?php printImageDesc(true); ?>




</div>`

The `<?php while (next_image()): ?>` is there to loop through all the images in the album and create a thumbnail list of all the images. When I comment it out along with the `<?php endwhile; ?>` the description appears but the thumbnail list no longer works.

Anyone know how to get both working simultaneously?

Thanks!
Developer
Developer
trisweb   2006-04-18, 06:15
#2
Interesting bug... so it works when there's no thumbnail list, but not when it's there...

You know, saving the _current_image isn't necessary (not since version 0.9 anyway), because that's already done in the loop.

Here's something to try... add this line *after* the image loop...

`<?php echo "Still in the image context? " . in_context(ZP_IMAGE); ?>`

If it says true, then it should work. I have a feeling it'll say false, and that's a bug I have to look at...
Member
Member
RogerUsh   2006-04-19, 05:26
#3
Thanks for replying! You are like the man of tech support!

Your "feeling" was right, it didn't work:
`Still in the image context? 0`

Good that you mention the version, this is actually a 0.8 version. Do you think we can find a work around without having to upgrade?

Or the other question is, do you think upgrading will fix it?
Developer
Developer
trisweb   2006-04-20, 00:33
#4
0.8 has context bugs, so bad in fact that placing other thumbnails on an image page won't even work. ;-)

Yes, upgrading should fix the problem. As a general rule-of-thumb, always upgrade before asking for help Smile Thanks.
Member
Member
RogerUsh   2006-04-20, 05:34
#5
Right, I'll try that upgrade right away.
  
Powered By MyBB, © 2002-2026 MyBB Group.
Made with by Curves UI.