bullbreed Posted February 24, 2010 Share Posted February 24, 2010 Hi. I'm looking for a little direction in creating my CMS project. I'm trying to create a dynamically driven navigation where the admin can add and remove pages. I have a form that ask for the following information Page Name - This is the text that is shown for the link Page Parent - For parent and child hierarchy Meta Title Meta Description Meta Keywords Page Content How do I create the links for the pages? I don't want the admin to have to type "about-us.php" I would like it so when the user adds (About Us) as a page name that the url says pid=2 or something like that. Any push in the right direction would be great. Link to comment https://forums.phpfreaks.com/topic/193277-cms-adding-pages-with-links/ Share on other sites More sharing options...
greatstar00 Posted February 24, 2010 Share Posted February 24, 2010 create a database like this pid, directory select * from pages where pid=$pid //your own code to do the mysql_query $rc=mysql_fetch_array($q) if(file_exists($rc['directory'])) include $rc['directory'] //to store stuff file_put_content($_POST['page_content'], $directory); NOTE: my directory means folder/filename.extension Link to comment https://forums.phpfreaks.com/topic/193277-cms-adding-pages-with-links/#findComment-1017727 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.