Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
PHP edit file on server?
#4
You have your editor.php, and then you have the line in code;
PHP Code:
$firstfile =  $_POST['page']; 
This will only work if you press "Submit" on editor.php, however you have another form on editpage-2.php which does submit to it self, $_SERVER['PHP_SELF'], but there is NO $_POST['page'] within this form, therfore you get an error "Undefined index: page"

The code I posted works as intended too, and if it's not what you want then read about using sessions and checking $_POST.
Reply


Messages In This Thread
PHP edit file on server? - by Inventor - 10-21-2011, 03:38 PM
RE: PHP edit file on server? - by Gaijin - 10-21-2011, 04:25 PM
RE: PHP edit file on server? - by Inventor - 10-21-2011, 04:57 PM
RE: PHP edit file on server? - by Gaijin - 10-22-2011, 04:24 AM
RE: PHP edit file on server? - by Inventor - 10-22-2011, 07:19 AM
RE: PHP edit file on server? - by saikiran - 08-08-2012, 04:05 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  PHP Framework List: An Ultimate Guide to 102 PHP Frameworks for Web Developers tk-hassan 0 936 07-27-2020, 11:26 PM
Last Post: tk-hassan
  Use PHP in a text file? Blic 4 1,506 10-25-2011, 08:12 PM
Last Post: Project Evolution
  PHP Video Tutorials (PHP For Beginners) Eleqtriq 4 3,660 10-10-2011, 01:00 PM
Last Post: Greyersting
  help : PHP : Executing .jar file killer_03 0 1,124 03-12-2011, 11:09 PM
Last Post: killer_03
  Common PHP and SQL [File-Sharing Site] Project Evolution 3 1,877 12-12-2010, 02:47 AM
Last Post: Bursihido

Forum Jump:


Users browsing this thread: 2 Guest(s)