battles/classes/input.php

19 lines
456 B
PHP
Raw Normal View History

2018-03-30 19:28:22 +00:00
<?php
/**
* Copyright (c) 2018.
* Author: Igor Barkov <lopar.4ever@gmail.com>
* Project name: Battles-Game
*/
class input
{
public static function get($name) {
2018-11-01 17:11:58 +00:00
rtrim($_GET[$name]);
return (isset($_GET[$name]) AND !empty($_GET[$name])) ? $_GET[$name] : null;
2018-03-30 19:28:22 +00:00
}
public static function post($name) {
2018-11-01 17:11:58 +00:00
rtrim($_POST[$name]);
return (isset($_POST[$name]) AND !empty($_POST[$name])) ? $_POST[$name] : null;
2018-03-30 19:28:22 +00:00
}
}