more handling of deliberately bad URLs

Turns out that pages.php and news.php should also have the test/404
error code since they can be reached via query links when mod_rewrite is
off