79
« on: August 03, 2011, 05:35:57 PM »
Hm.... In this requests we extract information from TEMP folder of the gallery... 4IMAGES_TEMP have only cat_id, but not have cat_name info... I think it`s not possible... But i`ll trying...
In awaiting.php find:
$sql = "SELECT i.image_id, i.cat_id, i.user_id, i.image_name, i.image_description, i.image_keywords, i.image_date, i.image_media_file, i.image_thumb_file".$additional_sql.get_user_table_field(", u.", "user_name")."
FROM (".IMAGES_TEMP_TABLE." i)
LEFT JOIN ".USERS_TABLE." u ON (".get_user_table_field("u.", "user_id")." = i.user_id)
WHERE i.user_id = $logged_in_id
ORDER BY i.image_date DESC
LIMIT $offset, $perpage";
And replace this:
$sql = "SELECT i.image_id, i.cat_id, c.cat_id, c.cat_name, i.user_id, i.image_name, i.image_description, i.image_keywords, i.image_date, i.image_media_file, i.image_thumb_file".$additional_sql.get_user_table_field(", u.", "user_name")."
FROM (".IMAGES_TEMP_TABLE." i, ".CATEGORIES_TABLE." c)
LEFT JOIN ".USERS_TABLE." u ON (".get_user_table_field("u.", "user_id")." = i.user_id)
WHERE i.user_id = $logged_in_id AND c.cat_id = i.cat_id
ORDER BY i.image_date DESC
LIMIT $offset, $perpage";
Try this