unidox Posted July 18, 2007 Share Posted July 18, 2007 Is it possible to have an if ($_REQUEST so like you go: index.php?id= the month minus the day and whatnot Link to comment https://forums.phpfreaks.com/topic/60654-if-_request/ Share on other sites More sharing options...
pocobueno1388 Posted July 18, 2007 Share Posted July 18, 2007 I don't understand what your trying to say at all. What are you wanting to do with the if statement? Link to comment https://forums.phpfreaks.com/topic/60654-if-_request/#findComment-301745 Share on other sites More sharing options...
unidox Posted July 18, 2007 Author Share Posted July 18, 2007 Like, I saw this one site, that to get to the admin panel, you had to subtract the day from the year. I was just wondering how you can do that Link to comment https://forums.phpfreaks.com/topic/60654-if-_request/#findComment-301748 Share on other sites More sharing options...
pocobueno1388 Posted July 18, 2007 Share Posted July 18, 2007 I guess you could do something like this: <?php $id = $_GET['id']; $day = date("d"); $year = date("Y"); //subtract day from year $final = $year - $day; if ($id == $final){ echo "You are allowed in the admin panel"; } else { echo "You are NOT allowed"; } ?> Link to comment https://forums.phpfreaks.com/topic/60654-if-_request/#findComment-301764 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.