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 'and t2.trad_published=1 order by t1.id' at line 5
SELECT t1.name from langues t1 inner join idsite2idlng t2 on t2.idln=t1.id and t2.idsite= and t2.trad_published=1 order by t1.id