php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #18860 4.2.2 breaks if/else statements
Submitted: 2002-08-11 16:31 UTC Modified: 2002-08-11 16:41 UTC
Votes:1
Avg. Score:3.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:0 (0.0%)
Same OS:0 (0.0%)
From: nmk at iki dot fi Assigned:
Status: Not a bug Package: Variables related
PHP Version: 4.2.2 OS: Solaris 8
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: nmk at iki dot fi
New email:
PHP Version: OS:

 

 [2002-08-11 16:31 UTC] nmk at iki dot fi
I had a simple script that is useless after I installed
php-4.2.2. Before I was using 4.1.0 and it worked fine.

It seems that in the php-4.2.2 it doesn't, for some odd reason, understand the posted $submit variable in the if-statement.

Any ideas?

- Niko

-- SCRIPT STARTS --

<?php

if($submit)
{
  echo $tellme;
} else {

?>
<h1>Tell me!</h1>

<form method="post" action="this-script.php">
<textarea name="tellme"></textarea>
<input type="Submit" name="submit" value="Tell it!">
</form>

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-08-11 16:35 UTC] nmk at iki dot fi
I had a simple script that is useless after I installed
   php-4.2.2. Before I was using 4.1.0 and it worked fine.

   It seems that in the php-4.2.2 it doesn't, for some odd reason,
   understand the posted $submit variable in the if-statement.

   Any ideas?

   - Niko

   -- SCRIPT STARTS --

   <?php

   if($submit)
   {
     echo $tellme;
   } else {

   ?>
   <h1>Tell me!</h1>

   <form method="post" action="this-script.php">
   <textarea name="tellme"></textarea>
   <input type="Submit" name="submit" value="Tell it!">
   </form>
<?php
}
?>
 [2002-08-11 16:41 UTC] rodif_bl@php.net
In PHP 4.2.0, the 'register_globals' setting default changed to
be off. See http://www.php.net/release_4_2_0.php for more info.
We are sorry about the inconvenience, but this change was a necessary
part of our efforts to make PHP scripting more secure and portable.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Nov 10 14:01:29 2024 UTC