By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,636 Members | 1,190 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,636 IT Pros & Developers. It's quick & easy.

Saving an array for the next page

P: n/a
My website has a dynamic navigation bar which the administrators of the site
can design. It's structure is held in an SQL database. It is displayed on
every page of the website.

For a browser, the NavBar has only two structures, one when he or she is not
logged on or logged on. An administrator can change its structure at any
time, however, which is recorded in the database.

One design approach is to build the NavBar for every page from the database,
changing its structure only if the browser logs on.

Is a more efficient way to load the structure from the database into a
JavaScript array and use that array on each new page, only refreshing it to
the new structure if the browser logs on?

Hence my subject; can I save a JavaScript array for the next page the
browser links to? If this is possible, is it worth the effort ie is there a
significant performance improvement?

The website uses ASP, VBScript and MS SQL on the server.

Many thanks in anticipation.

Posted Via Premium Usenet Newsgroup Services
Oct 5 '05 #1
Share this Question
Share on Google+
1 Reply

P: n/a
Your server side implementation has no effect on the limitations and
abilities of JavaScript and the DOM.

The only simple way to keep the Array of data is by using frames by
using one of the frames to store your persistent data.

Another way to do this is to generate a JavaScript file unique for each
user and have JS file named specific to the users context. When the
user logs in, the server generates a new JS file with the DataStructure
in it and passes the unique name to the html source. On all subsequent
requests, the following pages request the same JS file name. This
feature does assume that the data structure is static across the entire


Oct 6 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.