Are you restarting Apache (or whatever webserver you're using) between edits to php.ini? I assume since you also posted this to php-win that you're using Win32. This would be my first step if you haven't done so already.
I got corrected on this before, saying that you -don't- have to restart between edits, but trust me, you do. I made changes to php.ini, saved, and no changes were noted until AFTER I restarted Apache. Apache does parse php.ini on startup because I entered invalid pathnames in various places as a test, and only on restart did I get a notice that the pathnames were invalid. I'm using Win32, PHP v4.1.2 as a module (not CGI), Apache 1.3.something. Jason Soza ----- Original Message ----- From: "Bill Hudspeth" <[EMAIL PROTECTED]> Date: Monday, June 10, 2002 2:16 pm Subject: [PHP] self processing forms > I am using the O'Reilly "Programming PHP" manual, and have copied > the code > from Example 7.3, p. 166. I have the magic_quotes_gpc set to ON in > php.ini(though toggling between on and off doesn't seem to have > any effect). My > processed form reports "0.00F is -17.78C " regardless of the initial > fahrenheit temperature I enter. Moreover, using another version of > thisscript, as shown in Example 7.4, p. 167, simply clears the > text field, and > never returns an output. I can't figure out why I am not getting a > correctoutput - perhaps something in my php.ini file? A copy of > the code I am using > (Example 7.3) is as follows: > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> > > <html> > <head> > <title>Untitled</title> > </head> > > <body> > > <?php > if ($_SERVER['REQUEST_METHOD'] == 'GET'){ > ?> > > <form action="<?php echo $_SERVER['PHP_SELF'] ?>" method="POST"> > Fahrenheit temperature: > <input type="text" name="fahrenheit' /> > > <input type="submit" name="Convert to Celsius!" /> > </form> > > <?php > } elseif ($_SERVER['REQUEST_METHOD'] == 'POST') { > $fahr=$_POST['fahrenheit']; > $celsius=($fahr - 32) * 5/9; > printf("%.2fF is %.2fC", $fahr, $celsius); > //echo "The temperature in degrees celsius is $celsius"; > } else { > die("This script only works with GET and POST requests."); > } > ?> > > </body> > </html> > > ************************************************** > > Thanks much in advance, Bill -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php