Changeset 3452 for trunk/admin


Ignore:
Timestamp:
Jun 24, 2009, 9:00:40 PM (15 years ago)
Author:
nikrou
Message:

Fix two problem with Feature 1026 :
use of $confuser_fieldsusername and $confuser_fieldsid instead of username and id
escape comment content before editing it.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/admin/comments.php

    r3450 r3452  
    135135
    136136$query = '
    137 SELECT c.id, c.image_id, c.date, c.author, u.username, c.content, i.path, i.tn_ext
     137SELECT c.id, c.image_id, c.date, c.author, '.
     138$conf['user_fields']['username'].' AS username, c.content, i.path, i.tn_ext
    138139  FROM '.COMMENTS_TABLE.' AS c
    139140    INNER JOIN '.IMAGES_TABLE.' AS i
    140141      ON i.id = c.image_id
    141142    LEFT JOIN '.USERS_TABLE.' AS u
    142       ON u.id = c.author_id
     143      ON u.'.$conf['user_fields']['id'].' = c.author_id
    143144  WHERE validated = \'false\'
    144145  ORDER BY c.date DESC
Note: See TracChangeset for help on using the changeset viewer.