get_settings('UserName', 'comments'); $ignore_all = 1; $query_select ="c.`Comment`, c.`Message_ID` AS MessageID, c.`id`, IF( UNIX_TIMESTAMP(c.`Updated`) > UNIX_TIMESTAMP(c.`Date`), DATE_FORMAT(c.`Updated`, '%d.%m.%Y %H:%i:%s'), DATE_FORMAT(c.`Date`, '%d.%m.%Y %H:%i:%s') ) AS `Created`, u.`User_ID`, u.`".($user_name ? $user_name : "Login")."` AS Login, c.`Guest_Name` AS Guest, sc.`Sub_Class_ID` AS SubClassID, sc.`Sub_Class_Name` AS SubClassName, sc.`Class_ID`, sc.`EnglishName`, sub.`Subdivision_ID` AS SubID, sub.`Subdivision_Name` AS SubName, sub.`Hidden_URL` AS SubURL"; $query_from = "`Comments_Text` as c"; $query_join = " LEFT JOIN `User` as u ON u.`User_ID` = c.`User_ID` LEFT JOIN `Sub_Class` as sc ON sc.`Sub_Class_ID` = c.`Sub_Class_ID` LEFT JOIN `Subdivision` as sub ON sub.`Subdivision_ID` = sc.`Subdivision_ID`"; $query_where = "c.`Checked` = 1"; $query_order = "`Date` DESC"; $query_limit = $cc_env['RecordsPerPage'] ? $cc_env['RecordsPerPage'] : "15"; ?>