forked from leftypol/leftypol
Referer checking; more descriptive error message
This commit is contained in:
parent
55743a7705
commit
67b954924b
3 changed files with 12 additions and 14 deletions
5
post.php
5
post.php
|
@ -151,9 +151,8 @@
|
|||
error($config['error']['bot']);
|
||||
|
||||
// Check the referrer
|
||||
if($OP) {
|
||||
if(!isset($_SERVER['HTTP_REFERER']) || !preg_match($config['url_match'], $_SERVER['HTTP_REFERER'])) error($config['error']['bot']);
|
||||
}
|
||||
if(!isset($_SERVER['HTTP_REFERER']) || !preg_match($config['referer_match'], $_SERVER['HTTP_REFERER']))
|
||||
error($config['error']['referer']);
|
||||
|
||||
// TODO: Since we're now using static HTML files, we can't give them cookies on their first page view
|
||||
// Find another anti-spam method.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue