Not signed in (Sign In)

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

    • CommentAuthoralexx
    • CommentTimeFeb 9th 2006
     
    Hi there,
    just tried out plogger. great piece of scripting.
    I'm trying to figure out how to add more info about pictures.
    By default is only "Dimesion" and "File Size".
    I can not find a way to fill other ones like "Taken..", "Camera", "Shutter.." ...
    thanx
    alex
    • CommentAuthorstoke
    • CommentTimeFeb 9th 2006
     
    Those are all EXIF data filled in by the camera. There's plenty of freeware that will let you edit it.
    • CommentAuthoralexx
    • CommentTimeFeb 9th 2006
     
    Ok thanx, I got that.

    But I have now a new problem: in IE6 and Opera 8, when thumb clicked from album I get this message:
    -----------------------
    Unknown column 'num_comments' in 'order clause'

    SELECT id FROM `plogger_pictures` WHERE parent_album = 2 ORDER BY `num_comments` DESC
    -----------------------
    in FireFox works OK.. could that be database thing..?
    thanx
    alex
    •  
      CommentAuthormike
    • CommentTimeFeb 9th 2006
     
    That's a bug in 2.1, it only happens when your images are sorted by "number of comments".

    We have fixed it in our development version, but if you want to fix it on your personal copy, there is a solution somewhere on the forum.
    •  
      CommentAuthormike
    • CommentTimeFeb 9th 2006
     
    http://plogger.org/forum/comments.php?DiscussionID=84
    • CommentAuthoralexx
    • CommentTimeFeb 9th 2006
     
    thanx for help,
    but it's still not working.
    I have next line's(136-140) in gallery.php
    ----------------------------------
    // fast query, even for big albums.
    $image_list = array();
    $sql = "SELECT id FROM `".$TABLE_PREFIX."pictures` WHERE parent_album = ".$row["parent_album"];

    // determine sort ordering
    -------------------------------------
    .. when I change line 139 in

    $sql = "SELECT p.`id`, COUNT(`comment`) AS `num_comments` FROM `".TABLE_PREFIX."pictures` p LEFT JOIN `".$TABLE_PREFIX."comments` c ON p.`id`=c.`parent_id` WHERE parent_album = ".$row["parent_album"]." GROUP BY p.`id` ORDER BY `num_comments` ";
    ---------------------------------
    .. I get in both IE and FF next error:

    You have an error in your SQL syntax near 'ORDER BY `date_submitted` ' at line 1

    SELECT p.`id`, COUNT(`comment`) AS `num_comments` FROM `TABLE_PREFIXpictures` p LEFT JOIN `plogger_comments` c ON p.`id`=c.`parent_id` WHERE parent_album = 2 GROUP BY p.`id` ORDER BY `num_comments` ORDER BY `date_submitted`
    -----------------------------------------------
    .. and I have 2.1 version

    any ideas..?

    the rest of the script is just beautiful....
    CSS could be just a bit more shorthand-ed.
    • CommentAuthorddejong
    • CommentTimeFeb 9th 2006
     
    CSS is entirely changed for Beta 3. In particular, all inline CSS was removed, CSS was streamlined and semantic (e.g. there are no longer members of "float-right" class, because if you wanted something to instead float-left, you would have to either change all of them -- having every member of "float-right" floating left -- or edit the markup generation).

    Wish I knew what to suggest for the above problems, but the problems are getting harder and harder to pointpoint. Sorry.

    Good luck,
    Derek
    •  
      CommentAuthormike
    • CommentTimeFeb 9th 2006 edited
     
    TABLE_PREFIX should be replaced with the value of the macro, it appears that TABLE_PREFIX is being embedded as text into your SQL queries. I think you are missing a dollar sign in front of the variable. Should be $TABLE_PREFIX.


    SELECT p.`id`, COUNT(`comment`) AS `num_comments` FROM `TABLE_PREFIXpictures`


    Should be processing as


    SELECT p.`id`, COUNT(`comment`) AS `num_comments` FROM `plogger_pictures`
    •  
      CommentAuthormike
    • CommentTimeFeb 9th 2006
     
    BTW, it was my mistake I had omitted the dollar sign in the code I posted. Hope that works for you.
    • CommentAuthoralexx
    • CommentTimeFeb 10th 2006
     
    Mike,
    Thanx I really appreciate you afford to help.
    But I donā??t get it.. some things.
    about you last post: I have to replace from line 139

    $sql = "SELECT id FROM `".$TABLE_PREFIX."pictures` WHERE parent_album = ".$row["parent_album"];

    to..

    SELECT p.`id`, COUNT(`comment`) AS `num_comments` FROM `plogger_pictures`

    ??

    about that dollar sign..? from where..?
    • CommentAuthorddejong
    • CommentTimeFeb 10th 2006
     
    SELECT p.`id`, COUNT(`comment`) AS `num_comments` FROM `$TABLE_PREFIXpictures`

    Because $TABLE_PREFIX = "plogger_"; therefore, it becomes:

    SELECT p.`id`, COUNT(`comment`) AS `num_comments` FROM `plogger_pictures`

    Without the "$", it won't be replaced as a variable.

    Cheers,
    Derek
    • CommentAuthoralexx
    • CommentTimeFeb 10th 2006
     
    derek,
    funny thing is that I dont have in gallery.php file =>
    SELECT p.`id`, COUNT(`comment`) AS `num_comments` FROM `$TABLE_PREFIXpictures` ...
    and I mean with ('comment'). ..
    but I have =>
    SELECT COUNT(*) AS num_items FROM `".$TABLE_PREFIX."pictures`

    ??
    •  
      CommentAuthormike
    • CommentTimeFeb 10th 2006 edited
     
    Line 139 of gallery.php:

    You have,

    $sql = "SELECT p.`id`, COUNT(`comment`) AS `num_comments` FROM `".TABLE_PREFIX."pictures` p LEFT JOIN `".$TABLE_PREFIX."comments` c ON p.`id`=c.`parent_id` WHERE parent_album = ".$row["parent_album"]." GROUP BY p.`id` ORDER BY `num_comments` ";


    It should be,

    $sql = "SELECT p.`id`, COUNT(`comment`) AS `num_comments` FROM `".<b style="background: #00ff00">$TABLE_PREFIX</b>."pictures` p LEFT JOIN `".$TABLE_PREFIX."comments` c ON p.`id`=c.`parent_id` WHERE parent_album = ".$row["parent_album"]." GROUP BY p.`id` ORDER BY `num_comments` ";


    Notice all I did was add a dollar sign in front of TABLE_PREFIX in the first instance of the variable.
    • CommentAuthoralexx
    • CommentTimeFeb 11th 2006
     
    mike,
    thanx man..


    this is soooo embarrassing...