why remove it?
find
Code:
$txlst3 = mysql_query("SELECT COUNT(*) FROM thanks WHERE touid=" . $CURUSER["id"]) or sqlerr();;
replace
Code:
$txlst3 = mysql_query("SELECT COUNT(*) FROM thanks WHERE userid=" . $CURUSER["id"]) or sqlerr();
seemed to work fine for me then. could be wrong tho
*edit* Ok so didnt work as well as i thought. still gives some errors. but that will fix the sql error you get