note 75267 added to language.variables.external
| From: | hugo at school dot com | Date: | Mon, 21 May 2007 10:27:31 +0000 |
| Subject: | note 75267 added to language.variables.external | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-126788@lists.php.net to get a copy of this message | ||
<?php
if (isset($_POST['action']) && $_POST['action'] ==
'abgeschickt') {
echo '<pre>';
$handle = fopen ("namen.txt", "r");
$found = false;
while ( !feof($handle) and !$found )
{
$buffer = fgets($handle, 4096);
if ($_POST['name'] == trim($buffer))
{
$zahl = fgets($handle, 4096);
$found = true;
$zahl = $zahl * 0.18;
} else {
$zahl = "Kein Eintrag";
}
}
fclose ($handle);
echo $found == true ? '<p>'. $_POST['name'] . ' verbrauchte
' . $zahl . '</p>' : '<p>' . $zahl . '</p>';
echo '<a href="'. $_SERVER['PHP_SELF']
.'">zurück</a>';
echo '</pre>';
} else {
?>
<form action="<?php echo $_SERVER['PHP_SELF']; ?>"
method="post">
Name: <input type="text" name="name" /><br />
<input type="hidden" name="action" value="abgeschickt" />
<input type="submit" name="submit" value="Und ab!" />
</form>
<?php
}
?>
----
Server IP: 217.13.201.10
Probable Submitter: 82.83.150.129
----
Manual Page -- http://www.php.net/manual/en/language.variables.external.php
Edit -- https://master.php.net/note/edit/75267
Del: integrated -- https://master.php.net/note/delete/75267/integrated
Del: useless -- https://master.php.net/note/delete/75267/useless
Del: bad code -- https://master.php.net/note/delete/75267/bad+code
Del: spam -- https://master.php.net/note/delete/75267/spam
Del: non-english -- https://master.php.net/note/delete/75267/non-english
Del: in docs -- https://master.php.net/note/delete/75267/in+docs
Del: other reasons-- https://master.php.net/note/delete/75267
Reject -- https://master.php.net/note/reject/75267
Search -- https://master.php.net/manage/user-notes.php