Protect $_GET include - the noob way.


SUBMITTED BY: Guest

DATE: May 15, 2013, 7:23 p.m.

FORMAT: PHP

SIZE: 157 Bytes

HITS: 1254

  1. <?php
  2. include "$_GET['page']"; //unsafe
  3. include "$_GET['page']"."1" //safe, but you would have to name your files pagea.txt
  4. ?>

comments powered by Disqus