Not signed in (Sign In)

Vanilla 1.1.10 is a product of Lussumo. More Information: Documentation, Community Support.

    • CommentAuthorjack
    • CommentTimeNov 6th 2005
     
    I have a popup.php file I'm using to open the larger images directly. I'm trying to get the image caption and description to display beneath the image in that window but have only succeeded in doing so with the date. But I don't understand why the rest isn't shown.

    At the top of that page I have

    <?php
    include("plog-functions.php");
    include("plog-globals.php");
    global $inHead;
    global $config;
    ?>

    Then (after some other plogger code) in the body I have

    print '<div class="datumplustitel"><h4>' .get_picture_date(). ': ' . get_picture_caption() . '</h4> - ' . get_picture_description() . '</div>';

    The image is shown correctly, but the rest of the information is missing.

    What else is needed to get that information 'transported' into that popup file?
    • CommentAuthorjack
    • CommentTimeNov 7th 2005
     
    ... or perhaps another idea would be to get the large images (which in my case are the same images/format as the intermediate images) into a popup window, with the functionality of the next/previous, slideshow, caption and description.

    I know this can be done, I'm just not sure how?
    • CommentAuthorjack
    • CommentTimeNov 7th 2005
     
    ... it's me again ;). I've decided to go for a popup only. The inline images looks really good, but I want to have the opportunity to show a larger image if necessary, and that would mean needing at least twice the amount of diskspace. And because I will have hundreds of photographs, the thumb leading directly to the large image is the better choice.

    So my first question stands: how do I get the caption and description to show up in the popup?
    •  
      CommentAuthormike
    • CommentTimeNov 8th 2005
     
    are you using Beta 2 or the latest nightly?
    • CommentAuthorjack
    • CommentTimeNov 8th 2005
     
    Latest nightly.
    I'm trying out things right now :), but with no succes yet.

    This is what I came up with until now:

    in the head:
    <?php
    include("plog-functions.php");
    include("plog-globals.php");
    ?>

    and in the body:

    <?php
    $baseurl = $config["baseurl"];
    $src = $_REQUEST['src'];
    $picture = get_picture_by_id($src);
    $id = $picture["id"];

    connect_db();
    $sql = "SELECT * FROM `".$TABLE_PREFIX."pictures` WHERE id = $id";
    $result = run_query($sql);
    $row = mysql_fetch_assoc($result);

    $thumbdir = $baseurl."images/".$picture['path'];
    list($width, $height, $type, $attr) = getimagesize($thumbdir);
    echo '
    <script language="JavaScript">
    <!--
    this.resizeTo('.$width.'+80,'.$height.'+140);
    -->
    </script>';

    $imagepath = $baseurl."images/".$picture['path'];
    $imgtag = '<img class="photos" src="'.$imagepath.'" alt="'.$src.'"/>';
    $output = $imgtag;
    ?>
    <table width="100%" height="100%" cellspacing="0" cellpadding="0">
    <tr><td valign="middle" align="center">
    <a href="javascript:window.close();">
    <?php
    print $output;
    print '<div class="datumplustitel"><h4>' .get_picture_date(). ': ' . get_picture_caption() . '</h4> - ' . get_picture_description() . '</div>';
    ?>
    </a>
    • CommentAuthorjack
    • CommentTimeNov 11th 2005
     
    Any ideas yet Mike? Or is this perhaps too complicated at this moment and should I wait for the next beta? I know I'm missing some data in that popup file, some content from the gallery.php file that's causing those functions not to work, but I don't know what.