ok, then, u can do this way:
change the code u added into /includes/functions.php to this://-----------------------------------------------------
//--- Photo Of The Day --------------------------------
//-----------------------------------------------------
function get_potd_image($show_link = 1) {
global $site_template;
$potd_image = get_potd_id();
$template = 'potd_image';
show_image($potd_image, "", $show_link);
$potd_image = $site_template->parse_template($template);
return $potd_image;
}
function get_potd_id() {
global $site_db;
switch (POTD_SELECT_MODE) {
case "by_rating" : $select_mode = "i.image_rating"; break;
case "by_votes" : $select_mode = "i.image_votes"; break;
case "by_comments" : $select_mode = "i.image_comments"; break;
case "by_downloads" : $select_mode = "i.image_downloads"; break;
}
$cat_id_sql = get_auth_cat_sql("auth_viewcat", "NOTIN");
$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_active, i.image_media_file, i.image_thumb_file, i.image_download_url, i.image_allow_comments, i.image_comments, i.image_downloads, i.image_votes, i.image_rating, i.image_hits, c.cat_name".get_user_table_field(", u.", "user_name")."
FROM ".IMAGES_TABLE." i, ".CATEGORIES_TABLE." c
LEFT JOIN ".USERS_TABLE." u ON (".get_user_table_field("u.", "user_id")." = i.user_id)
WHERE i.image_active = 1 AND i.cat_id NOT IN ($cat_id_sql) AND c.cat_id = i.cat_id
ORDER BY $select_mode DESC
LIMIT 1";
$potd_image = $site_db->query_firstrow($sql);
$site_db->free_result();
return $potd_image;
}
//--- End Photo Of The Day ----------------------------
in details.php find:
//-----------------------------------------------------
//--- Print Out ---------------------------------------
//-----------------------------------------------------
$site_template->register_vars(array(
"msg" => $msg,
replace with:
$potd = get_potd_id();
if ($potd['image_id'] == $image_id) {
$potd_msg = "blah blah blah";
}esle{
$potd_msg = "";
}
//-----------------------------------------------------
//--- Print Out ---------------------------------------
//-----------------------------------------------------
$site_template->register_vars(array(
"potd_msg" => $potd_msg,
"msg" => $msg,
after that, in details.html template u can use those tags:
{if potd_msg}
---------Your html table, any code---------
{potd_msg}
---------Whatever u want----------
{endif potd_msg}