View Single Post
Old 10-14-2012, 12:08 PM   PM User | #7
VIPStephan
The fat guy next door


 
VIPStephan's Avatar
 
Join Date: Jan 2006
Location: Halle (Saale), Germany
Posts: 7,602
Thanks: 5
Thanked 865 Times in 842 Posts
VIPStephan is a jewel in the roughVIPStephan is a jewel in the roughVIPStephan is a jewel in the rough
I just wanted to chime in to say that simply changing the button type from “submit” to “button”, as OldPedant has suggested, is not the ideal solution because you basically remove the possibility to submit the form by pressing the button if JS isn’t available for whatever reason (and don’t come with “everyone has JS enabled nowadays”, this is such a simple issue that it doesn’t require you to jump through hoops to get it right). The better solution is the one DanInMa has suggested.
__________________
Don’t click this link!
VIPStephan is offline   Reply With Quote