[ale] javascript question

Ed Cashin ecashin at noserose.net
Fri Aug 7 13:29:01 EDT 2009


On Fri, Aug 7, 2009 at 12:16 PM, Geoffrey<lists at serioustechnology.com> wrote:
> I'm trying to find a short cut way to do something in javascript.
>
> Got a page full of fields.  User finishes inputing data, and submits.
> The data produces an error and therefore I need to refresh the page and
> let them fix the data.

I used to do that without javascript with CGI.  The CGI would just
produce a new page like the old one but with messages like,
"Your age must be a number" or "required field", red borders,
whatever, with their data in the fields where they put it.

The perl modules I was using made that easy, I think, but there
were times when I wanted to go to an intermediate page *before*
displaying the data-entry page again, and in those cases I just
created hidden fields on the intermediate page.  The hidden fields
contained the user's data.  (You could encrypt them symmetrically
if you wanted.)

But these days I'm interested in AJAX, and so I wonder whether
you could use the features in domassistant for your case.  You
could post the user data using the AJAX module:

  http://www.domassistant.com/documentation/DOMAssistantAJAX-module.php

... and then you could modify the content on the fly using the
content module:

  http://www.domassistant.com/documentation/DOMAssistantContent-module.php

At least that's what it looks like to me.  I would love to hear from anybody
who knows whether it's as applicable to the situation in question as I think
it is.  :)

-- 
  Ed Cashin <ecashin at noserose.net>



More information about the Ale mailing list