class.udb.php:167 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')
GROUP BY sites.siteid
) as `t`
WHERE ' at line 9
SELECT * FROM
(
SELECT areas.title as `atitle` ,`sites`.area, sites.city, cities.title as `ctitle`, sites.siteid, sites.avgStars, sites.totalStars ,thanks.id , thanks.message, thanks.author, thanks.title as `thankTitle`, thanks.time, thanks.stars, sites.picture as 'picSite', sites.disableAutoConfirm ,sites.siteAltPic, sites.siteTitlePic
FROM thanks
INNER JOIN sites USING(siteid)
LEFT JOIN areas ON (`sites`.area=`areas`.id)
LEFT JOIN superareas ON (`superareas`.id=areas.superareas)
LEFT JOIN cities ON (`sites`.city=`cities`.id)
WHERE sites.`ifShow`=1 AND thanks.ifshow=1 AND thanks.title !='' AND sites.avgStars >= 4 AND thanks.message!='' AND sites.siteid IN (541,543,544,539,536,537,)
GROUP BY sites.siteid
) as `t`
WHERE t.avgStars >= 4 AND t.stars >= 4
ORDER BY RAND()
LIMIT 10
1: class.udb.php:282 udb::query()
2: inc_textpage.php:822 udb::key_row()
3: index_new_site.php:1337 include()
4: index.php:50 include()