logo

New Response

« Return to the main article

You are replying to:

  1. I think this is an important side-note for using pop-ups, although it will be obvious to some.

    When I first began creating pop-up windows, I used a form to create the pop-up because I needed to do some lookups to populate fields in the pop-up. Of course, this requires an additional request to the server and processing time.

    Now, I put my lookups on the main form and create the pop-up by constructing the HTML, complete with JS functions, on the fly via JavaScript avoiding additional server hits until the form is actually submitted.

    The JavaScript function can be a little hairy since HTML syntax can be difficult enough by itself. More tips to make this easier: 1. Use linked resources such as CSS sheets and JavaScript source files. 2. Create the pop-up in the HTML editor of your choice, cut-n-paste the HTML into the JavaScript routine, and, finally, add any additional script that you will need to generate drop-down lists, checkbox lists, etc.

Your Comments

Name:
E-mail:
(optional)
Website:
(optional)
Comment: