DanielWhite Posted April 4, 2008 Share Posted April 4, 2008 First of all I would like to ask if anyone knows how I can use a form to create a PHP file. For example. User inputs text into HTML based form and then clicks submit. The data then gets saved inside a newly created PHP file. Anyone know how to? My second question is, does anyone know where I can get a hold of the file for phpBBcode so that I can use BB codes on my php pages. I looked on Google and all the download sites get errors. Thank you, Daniel White Link to comment https://forums.phpfreaks.com/topic/99583-2-questions-using-a-form-to-create-a-html-file-phpbbcode-file/ Share on other sites More sharing options...
GingerRobot Posted April 4, 2008 Share Posted April 4, 2008 1.) The file system functions such as fwrite and fread will be needed: http://uk2.php.net/manual/en/ref.filesystem.php 2.) These tutorials may be of interest to you: http://www.phpfreaks.com/forums/index.php/topic,186690.0.html http://www.phpfreaks.com/forums/index.php/topic,186697.0.html http://www.phpfreaks.com/forums/index.php/topic,186705.0.html Link to comment https://forums.phpfreaks.com/topic/99583-2-questions-using-a-form-to-create-a-html-file-phpbbcode-file/#findComment-509456 Share on other sites More sharing options...
DanielWhite Posted April 4, 2008 Author Share Posted April 4, 2008 Umm is it just me or is there lots of the tutorial coding missing of here: http://www.phpfreaks.com/forums/index.php/topic,186690.0.html ??? 1.) The file system functions such as fwrite and fread will be needed: http://uk2.php.net/manual/en/ref.filesystem.php 2.) These tutorials may be of interest to you: http://www.phpfreaks.com/forums/index.php/topic,186690.0.html http://www.phpfreaks.com/forums/index.php/topic,186697.0.html http://www.phpfreaks.com/forums/index.php/topic,186705.0.html UPDATE: OK here's a tutorial to create files: http://www.developer.com/lang/php/article.php/1146721 However, I am still looking for the phpBBcode file. Could anyone help me? Thank you. Link to comment https://forums.phpfreaks.com/topic/99583-2-questions-using-a-form-to-create-a-html-file-phpbbcode-file/#findComment-509464 Share on other sites More sharing options...
DanielWhite Posted April 4, 2008 Author Share Posted April 4, 2008 Here's a quick way to create a file: http://www.somecoders.com/2006/06/creating-files-with-php/ <?php //Create the file mck.php $handle = fopen('mck.php', 'w+'); //Write some text fwrite($handle, "Hmm, there's no PHP here!", 25); //Close the file fclose($handle); ?> Link to comment https://forums.phpfreaks.com/topic/99583-2-questions-using-a-form-to-create-a-html-file-phpbbcode-file/#findComment-509475 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.