copied from wsCore's Validation and added require.php.