PHP Classes

File: start.php

Recommend this page to a friend!
  Classes of Muhammad Umer Farooq   PHP CSRF Token Generation   start.php   Download  
File: start.php
Role: Example script
Content type: text/plain
Description: Example script
Class: PHP CSRF Token Generation
Generate tokens to protect against CSRF attacks
Author: By
Last change: Apply fixes from StyleCI
Date: 4 years ago
Size: 471 bytes


Class file image Download

require_once 'init.php';

$security = new CSRF();


if (
is_submit('submit')) {

//i use my input class you can as well use _GET or _POST method thanks

if ($security->Verify(input('token'))) {

'<div class="container">'.restore_new_lines(input('q')).'</div>';
    } else {
'invilid request';

//only for debug purpose