DATABASE ERROR:
SELECT
					u.*,
					a.photo_premod,
					a.photo_reject,
					a.photo_thumb
				FROM users u
					LEFT JOIN users_album_photos a ON u.id = a.photo_sender_id AND a.photo_views = 1
					INNER JOIN users_online o ON u.id = o.online_id
					
				WHERE u.act_status = 'y' AND u.search_mode = 1 AND u.is_locked = 0  AND (u.is_hidelast_access = 0)

				
				ORDER BY u.risdate DESC
				LIMIT -10, 20
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 '-10, 20' at line 14