Hi!
1.) suche in root/details.php:
$admin_links .= ($config['user_delete_comments'] != 1) ? "" : "<a href=\"".$site_sess->url(ROOT_PATH."member.php?action=removecomment&".URL_COMMENT_ID."=".$comment_row[$i]['comment_id'])."\">".$lang['delete']."</a>";
}
füge darunter ein:
elseif ($user_info['user_id'] == $comment_row[$i]['user_id']) {
$admin_links .= ($config['user_edit_comments'] != 1) ? "" : "<a href=\"".$site_sess->url(ROOT_PATH."member.php?action=editcomment&".URL_COMMENT_ID."=".$comment_row[$i]['comment_id'])."\">".$lang['edit']."</a> ";
}
2.) suche in root/member.php:
$sql = "SELECT c.comment_id, c.image_id, i.image_name, i.cat_id, i.user_id".get_user_table_field(", u.", "user_name")."
FROM (".COMMENTS_TABLE." c, ".IMAGES_TABLE." i)
LEFT JOIN ".USERS_TABLE." u ON (".get_user_table_field("u.", "user_id")." = c.user_id)
WHERE c.comment_id = $comment_id AND i.image_id = c.image_id";
$comment_row = $site_db->query_firstrow($sql);
if (!$comment_row || $comment_row['user_id'] <= USER_AWAITING || ($user_info['user_id'] != $comment_row['user_id'] && $user_info['user_level'] != ADMIN)) {
ersetze es mit:
$sql = "SELECT c.user_id AS comment_user_id,c.comment_id, c.image_id, i.image_name, i.cat_id, i.user_id ".get_user_table_field(", u.", "user_name")."
FROM (".COMMENTS_TABLE." c, ".IMAGES_TABLE." i)
LEFT JOIN ".USERS_TABLE." u ON (".get_user_table_field("u.", "user_id")." = c.user_id)
WHERE c.comment_id = $comment_id AND i.image_id = c.image_id";
$comment_row = $site_db->query_firstrow($sql);
if (!$comment_row || $comment_row['comment_user_id'] <= USER_AWAITING || ($user_info['user_id'] != $comment_row['comment_user_id'] && $user_info['user_level'] != ADMIN)) {
2.1) suche:
if (!$comment_row || $comment_row['user_id'] <= USER_AWAITING || ($user_info['user_id'] != $comment_row['user_id'] && $user_info['user_level'] != ADMIN)) {
header("Location: ".$site_sess->url($url, "&"));
ersetze es mit:
if (!$comment_row || $comment_row['comment_user_id'] <= USER_AWAITING || ($user_info['user_id'] != $comment_row['comment_user_id'] && $user_info['user_level'] != ADMIN)) {
header("Location: ".$site_sess->url($url, "&"));
bitte testen...
mfg Andi