zenphoto forums » General Zenphoto Discussion

Problem getting thickbox to work with zenphoto

(9 posts)
  1. Jahan77

    Member
    Joined: Dec '08
    Posts: 16

    Hello Everybody,

    I was wondering if any of you could figure this out.

    I am using thickbox, to get a pop up window (similar to lightbox), for a zenphoto gallery I've set up.

    However, after I put in the code I thought was right, and click on the thumbnail, instead of the full image popping up, a window pops up containing gibberish characters.

    It seems that when the link is clicked, the browser treats the image as though it were a page, and renders it thusly.

    Here is the code I used in album.php:

    <a class="thickbox"
    href="<?=getFullImageURL();?>"
    rel="[<?=getAlbumTitle();?>]" title="<?=getImageTitle();?>"><?php printImageThumb(getImageTitle()); ?>

    Is the code wrong, and if so, what code should I use instead?

    Thanks in advance for any help!

    -Jahan

    Posted 4 years ago #
  2. Jahan77

    Member
    Joined: Dec '08
    Posts: 16

    I thought I'd mention that I already tried using this:

    <a
    href="<?php echo htmlspecialchars(getFullImageURL());?>

    That made a window into a page containing the image, instead of just the image itself.

    I want the image only, within the thickbox window.

    Thanks,

    -Jahan

    Posted 4 years ago #
  3. Jahan77

    Member
    Joined: Dec '08
    Posts: 16

    I thought I'd mention that I tested this by taking out the php, and putting a url to an existing image.

    This worked - an image was displayed correctly in the thickbox window.

    But this was just to test it.

    It can't be a solution, since the same large image will be shown, regardless of which thumbnail I click on.

    ...the whole point of having a zenphoto gallery, is for it to be dynamic.

    Posted 4 years ago #
  4. Zenphoto development team
    acrylian

    Developer
    Joined: Jul '07
    Posts: 13,350

    You need to either disable the full image protection or use the getUnprotectedFullimageURL() function (please see the functions guide for the correct spelling). The thickbox needs direct access to the full image.

    Don't forget to read the Forum rules and usage resources
    Posted 4 years ago #
  5. Jahan77

    Member
    Joined: Dec '08
    Posts: 16

    Thanks alot, that worked!!

    One minor problem: I noticed that in firefox, when the thickbox window is activated by clicking on the thumbnail, the background doesn't darken the way it is supposed to - but the thing works normally in Safari.

    Any idea why?

    -Jahan

    Posted 4 years ago #
  6. Zenphoto development team
    acrylian

    Developer
    Joined: Jul '07
    Posts: 13,350

    Don't know either there is something missing or it's a firefox thing.

    Don't forget to read the Forum rules and usage resources
    Posted 4 years ago #
  7. Jahan77

    Member
    Joined: Dec '08
    Posts: 16

    Oh, forgot to mention that I'm on a Mac - the problem doesn't appear on a PC, when using Firefox, only when using Firefox on a Mac.

    Posted 4 years ago #
  8. Zenphoto development team
    acrylian

    Developer
    Joined: Jul '07
    Posts: 13,350

    Yeah, I am on Mac, too and noticed that. No idea though.

    Don't forget to read the Forum rules and usage resources
    Posted 4 years ago #
  9. Jahan77

    Member
    Joined: Dec '08
    Posts: 16

    Ah, I found it.

    There's a file apparently missing from the Thickbox files.

    It's macFFBgHack.png - I googled it, and downloaded it, and now it works.

    The code for it was already there, for the hack, but this file was missing.

    Posted 4 years ago #

RSS feed for this topic

Reply

You must log in to post.