New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
value lost in submit #55
Comments
Are you submitting the form with Ajax (in which case can you post that code)? Or just a regular |
thanks for the fast reply.
this is all the code involved i think |
Are you sure the other form values are submitting successfully? |
yes, this is the array that arrive in the second page Array ( [nome] => Prova [telefono_vis] => on [cellulare_vis] => on ) |
And if you don't initialise the plugin, what values do you get? |
this one: |
That's very strange. I don't see how the plugin could be causing that. I used your code to make a test case and it seems to be working fine (http://plnkr.co/edit/JnHAVgN2x7GQW90mGRRr?p=preview). I just changed the save button to have type="submit" so it directly submits the form, and changed the If you view that in Chrome, and open Chrome Dev Tools, look at the Network tab, and filter by Documents, and then click the "save" button on the form, you will see that it makes a GET request with all of the args - see this screenshot: I would advise you to try and simplify your test case to figure out what's causing the problem. Make sure you don't have any other libs/plugins interfering with your code. |
thanks for your reply. |
I adjusted my example to do that and it works fine (try it - just hit save). Can you try and reproduce your problem somewhere I can see it running, like on your website, or on Plunker or something? |
i just did it on plunker.
|
Can you send me a link to the Plunker? |
The problem is that you've got a form element directly inside a table element, which is invalid. In the Plunker, you can see the red error message on line 35. You just need to move the table inside the form. |
Wow. that was the problem! i am sorry to made you waste your time for such a stupid error. |
Hello.
first of all thanks for everything.
i am trying to register some users data using intl-tel-input for telephone numbers. when i submit the form i lose the field value if i add the scripts. I tried without and it arrives at the second page.
this is the code:
input type="tel" name="mobile" id="mobile" size="20" />
span id="valid-msg" class="hide">✓ Valid
span id="error-msg" class="hide">Invalid number
script>
var telInput = $("#mobile"),
errorMsg = $("#error-msg"),
validMsg = $("#valid-msg");
/script>
the message on the next page is:
Notice: Undefined index: mobile in C:\xampp\htdocs\mioprogetto\amministrazione\elaboraVenditore.php on line 12
i can't understand what i am doing wrong...
thanks for your help
The text was updated successfully, but these errors were encountered: