Link to home
Start Free TrialLog in
Avatar of jdav357
jdav357

asked on

JQuery suggestions for dynamic buttons in Modal Window

Hi,
I have a standard for with standard HTML submit buttons etc.
When the page is loaded as a standalone page then showing these buttons is fine. I have made the script so only the form is loaded into a modal window, without the rest. In the modal  window the buttons are set using Jquery parameters.
What I would like to be able to do is load any form using the same script, but where it finds a html button in the form it replaces it with a modal window button and if its a submit button then it should submit when clicked. It should also hide the html buttons that its replacing.

The reason why I am trying to achieve this, is so I can re-use the same javascript to open any forms that are requested, rather than creating a function for each form and having to set up the buttons for each one.

Cheers
John
ASKER CERTIFIED SOLUTION
Avatar of SRigney
SRigney
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial