Permalink
Show file tree
Hide file tree
2 comments
on commit
sign in to comment.
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
3 changed files
with
18 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); | ||
|
||
function validate_method() | ||
{ | ||
|
||
$url = $_SERVER['REQUEST_URI']; | ||
|
||
$post_required = preg_match('/(save|delete|delete_item)\/?\d*?/', $url); | ||
|
||
if($post_required && $_SERVER["REQUEST_METHOD"] != "POST" && empty($_POST)) | ||
{ | ||
echo "Method not allowed"; | ||
die; | ||
} | ||
|
||
} |
This file was deleted.
Oops, something went wrong.
e8f27f5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for doing all this on your time off.LOL
e8f27f5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Back home already here, had a busy day indeed