File creator from PHP
Posted: Fri Jan 28, 2011 8:09 pm
I'm creating a website for my teacher. They are not very bright with html, so I'm making it easier on them by making a php based page generator.
What I'm looking for here is I need to know how to create a file based on user input. Basically:
where $pageName would show up as the header at the top of the page, and others for the lesson content.
What I'm looking for here is I need to know how to create a file based on user input. Basically:
Code: Select all
<?php
if(isset($_POST['submit'])) {
$pageName=$_POST['pageName'];
if($pageName) {
//code to make file
}
}
?>