[Javascript] Form focus

Mike Dougherty mdougherty at pbp.com
Mon May 10 14:19:16 CDT 2004


>You're welcome.  Let the group know if you have any difficulties implementing it.
>Some minor things can be major annoyances if you're new to JS.

   I'm not really new to JS anymore (I still complain, but about different issues)

Is there a way to store an associative array in the ASP application object?  I know you can't 
store a vbscript 'dictionary' object (which essentially mimics the associative array concept)

If javascript arrays can be stored in the application scope of an ASP environment, i would be 
tempted to change my ways to server-side javascript.  

I know i could just test this, but if i ask here and someone knows why that would be bad then i 
don't have to spend time building something that may not work.

example:  I'm working on a menu system that uses the xmlhttp example provided by Hakan Magnusson 
on 5/5/04 to retrieve sub menu items from a menu server applet given a node in the menu tree.  The 
menu data will come from SQL, but that lookup is a fairly expensive process which could be 
repeated frequently by each visitor.  If the menu server applet could store the results (as 
assemled, returnable HTML) the cache could serve the string much more efficiently than going to 
the database for the same content. 
   I implemented a cache like this once with vbscript, but each hit on the cache required an 
iterative search through a plain old vbscript array (because the dictionay object cannot be stored 
in application scope)  It would be much simpler/faster to use a javascript associative array for 
this cache.

Any suggestions about server-side javascript in ASP, menu cacheing, etc. would be welcomed.



More information about the Javascript mailing list