akrohn Posted February 25, 2012 Share Posted February 25, 2012 In a form example I am learning from I came across the value of the submit button being 'Next &rarr'. Could anyone explain this to me rather than using a value that sends you to another page to process the form? In this example what I am trying to learn is form validation using a function that checks for letters and numbers only. Link to comment https://forums.phpfreaks.com/topic/257776-form-submit-where-value-next-rarr/ Share on other sites More sharing options...
kicken Posted February 26, 2012 Share Posted February 26, 2012 Not sure if I really understand what your question is, but... The value attribute of a button just controls what text is displayed in the button. A value of 'Next →' would end up in a button with a label that looks like Next ->. From the scripts point of view, the value of a button is fairly meaningless. Usually you just check if a button was clicked by looking for it's name, eg: if (isset($_POST['btnNext'])){ would test if the next button was pressed, assuming you have name="btnNext" in your HTML code. Link to comment https://forums.phpfreaks.com/topic/257776-form-submit-where-value-next-rarr/#findComment-1321326 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.