Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ##index.php
- <?php
- $ninja = mysql_real_escape_string($ninja); // protect from sql injection.
- require_once 'store_ninja.php'; // pretend this is a tough enough task that we'd put it in its own file
- //Do other things, make pretty poniz.
- ?>
- ##store_ninja.php
- <?php
- $query = "insert into table_ninjas (name) values '" . $ninja . "';";
- mysql_query($query);
- ?>
Add Comment
Please, Sign In to add comment