Hello,
I have a form with three tabs. Each tab has more than one fields and one Save to Continue button for jumping to next tabs. Save to Continue is a normal button, it doesnot save the details entered to database. Following is the code for button:
<div class="to_tabs" ><input type="button" class="to_tab savebtn" value="Save & Continue" name="about" id="1"></div>
Put a load JS action on onload event and inserted following code make these button jumbp in between tabs:
I want to put validation in each tab itself, it should display error message when I jump to next element itself or when I click on Save and Continue button of each tab. That is it should restrict the user to get next tab, if any field inside the current tab have any validation error. I have provided require validation for every field.
Thanks and Regards,
Soumya
I have a form with three tabs. Each tab has more than one fields and one Save to Continue button for jumping to next tabs. Save to Continue is a normal button, it doesnot save the details entered to database. Following is the code for button:
<div class="to_tabs" ><input type="button" class="to_tab savebtn" value="Save & Continue" name="about" id="1"></div>
Put a load JS action on onload event and inserted following code make these button jumbp in between tabs:
window.addEvent('domready', function() {
$$('div.to_tabs input').each(function(el) {
el.addEvent('click', goTab);
});
});
function goTab(){
pane = $('#cf_tabbed_form dl')[0].retrieve('JTabs');
pane.display(this.getProperty('id'));
}
I want to put validation in each tab itself, it should display error message when I jump to next element itself or when I click on Save and Continue button of each tab. That is it should restrict the user to get next tab, if any field inside the current tab have any validation error. I have provided require validation for every field.
Thanks and Regards,
Soumya