My page has two forms of welcome.php as shown:
Lt; Form action = "welcomeforms.php" method = "post" name = "food security" & gt; & Lt; H4 & gt; & Lt; / H4 & gt; // spacer & lt; Input type = "text" name = "breakfast_calleries" value = "calorie amount" onFocus = "this.value = ''" & gt; & Lt; Br> & Lt; Input type = "submit" style = "position: full; left: -9999px; width: 1px; height: 1px;" & Gt; & Lt; / Form & gt; & Lt; Form action = "welcomeforms.php" method = "post" name = "foods" & gt; & Lt; H4 & gt; Breakfast & lt; / H4 & gt; & Lt; Input type = "text" name = "breakfast" value = "add new snack item" focus = "this.value = ''" & gt; & Lt; Br> & Lt; Input type = "submit" style = "position: full; left: -9999px; width: 1px; height: 1px;" & Gt; & Lt; / Form & gt;
This is the code at welcomeforms.php:
if (isset ($ _ POST ['breakfast'])) {$ breakfastitem = $ _POST [ 'Snack'];} (Prozate ($ _ POST ['breakfast_calleries']) $ $ Snack Goods = $ _POST ['breakfast_calleries'];} $ echoes snack; $ Dancer;
Forms are displayed correctly on the webpage, and when I enter 'Roti' and '100' in the breakfast form in the form of breakfast, this same webpage Is given on:
irreversible variable: breakfastitem in C: \ wamp \ www \ welcomeforms.php line on line 100
these forms with my eyes Basically the same, so I do not understand why a post is worth the right price and nothing else does not post anything Is such a ridiculous thing that I have missed?
You are using two different forms and you submit You can only merge them into one at a time.
Instead of using value = "add new snack item", use the focus = "this.value = ''"
bus placeholder = "Add new snack item"
- Find what you want to get in the modern browsers - help:
No comments:
Post a Comment