היי,
יצרתי טופס HTML שאמור לשלוח נתונים לקובץ PHP. מופיע לי מסך לבן והECHO אינו מציג דבר.
קוד הHTML הוא:
HTML קוד:
<form action="index2.php" method="post">
Number 1: <input type = "text" name = "calculator [num1]"><BR />
Action [+, -, /, *]: <input type = "text" name = "calculator [action]" size=1 maxlength=1><BR />
Number 2: <input type = "text" name = "calculator [num2]"><BR />
<input type="submit" value="Go!">
</form>
הקובץ index2.php הוא:
PHP קוד:
<?php
$calculator1 = $_post ["calculator"] ['num1'];
echo $calculator1;
?>
כמו שאתם רואים, אני רוצה להציג רק את המשתנה num1 במערך calculator.
אני יודע שהמשתנה calculator1 אינו נחוץ, סתם ניסיתי דרך אחרת שגם לא פעלה.
תודה רבה לעוזרים

.