4images Forum & Community
4images Modifications / Modifikationen => Mods & Plugins (Releases & Support) => Topic started by: Rembrandt on December 31, 2011, 08:08:11 PM
-
Hi!
The desire come from here, http://www.4homepages.de/forum/index.php?topic=30441.0
1.) search in includes/functions.php:
function show_image($image_row, $mode = "", $show_link = 1, $detailed_view = 0) {
insert above:
function user_comments($image_id = 0, $user_id = 0) {
global $site_db, $user_table_fields;
if ($user_id != GUEST ) {
$sql = "SELECT COUNT(comment_id) AS comments
FROM ".COMMENTS_TABLE."
WHERE image_id = $image_id AND user_id = $user_id";
$countcomments = $site_db->query_firstrow($sql);
}
return $countcomments['comments'];
}
1.2) search:
$user_name_link = $user_name;
}
insert below:
$user_comments = user_comments($image_row['image_id'],$user_info['user_id']);
1.3) search:
"image_comments" => $num_comments,
insert below:
"user_comments"=> ($user_comments) ? $lang['count_user_comment']."<span class=\"new\">".$user_comments."</span>":"",
2.) search in lang/YourLang/main.php above "?>"
Deutsch
$lang['count_user_comment'] = "Eigene Kommentare: ";
English
$lang['count_user_comment'] = "Own Comments: ";
3.) search in templates/YourTemplates/thumbnail_bit.html:
{image_comments}
and replace:
{image_comments}<br>{user_comments}
4.) search in templates/YourTemplates/details.html:
{if allow_comments}
insert below, or where ever you want:
{user_comments}<br>
mfg Andi
-
Dankeschön! das funktioniert einwandfrei!
saubere Arbeit, so habe ich mir das gewünscht, lieber Andi.
-
Danke dir, sowas hört man gerne. :D