Javascript Tooltip / Posts /

Popup tooltip from a field that fails validation when submitting form

2
Hi,
We have a form to be filled, if we leave any field empty and clicking submit, then a tooltip should display at the particular field.
How to achieve it..
Shanker  10 years ago   viewed: 4856    

1 Answer

0

Download the tooltip package, and you can easily figure it out from the demo4.html.

Suppose the field element is <input id="field2" type="text" name="LastName" value="Mouse">, then if your validation before submitting the form has found field2 is not valid, you can call the popUpFailedValidation() function:

function popUpFailedValidation(){

tooltip.pop("field2", "#tip2", {position: 1});

}

Andry   10 years ago

   

Your name*
Password
(Optional. Used to modify this post afterwords)
+ =  

Ask your Own Question

  • If your question is related to the topic of this post, you can post your question to this page by clicking the "Post a reply" button at left;

  • When you want to start a new page for your question: