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 (publish_up = '0000-00-00 00:00:00' OR publish_up <= '2010-09-03 17:00:41') ' at line 5 SQL=SELECT id, subject, send, hits FROM `jos_letterman`
WHERE
published=1 AND
access <=
AND (publish_up = '0000-00-00 00:00:00' OR publish_up <= '2010-09-03 17:00:41')
AND (publish_down = '0000-00-00 00:00:00' OR publish_down >= '2010-09-03 17:00:41')
ORDER BY created DESC
LIMIT ,