Links

Lists

Latest Updates

Ruby On Rails List
Python list
Advanced Java
The JavaScript List
Apache Users
Full Disclosure
Linux Security

Search the archives!


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Javascript] Saving pages (a different solution)


  • From: javascript@xxxxxxxxxx (Roger Roelofs)
  • Subject: [Javascript] Saving pages (a different solution)
  • Date: Fri, 31 Aug 2001 13:52:31 -0400

You could build the page on the fly by saving your data to a .js 
file...something like

// data.js
data = new Array();
//                  ID,     Model,       Price...
data[0] = new Array('XP101','MegaSew101','450.00');
data[1] = new Array('X205','MiniSew205','250.00');
...

Build a generic page that includes the data.js file.  Then customize the 
page on the fly based on which model the user chooses.

The big downside is that data sets of more than about 500 rows can be 
sluggish on older machines.  I confess that I typically load the data 
into a bare page in an invisible frame so I don't have to re-request it 
from the server more than once per session.

On Friday, August 31, 2001, at 01:01  PM, javascript-request@xxxxxxxxxx 
wrote:

>
> I am using JavaScript to generate product pages
> from data in a .js file for a small sewing shop store
> with image links, text and order buttons.
>
> Then I copy and paste the code into note pad and
> save them with .htm extensions.
>
> They are simple HTML pages and work just fine.
>
> Is there a better and faster way to save the pages ?
> I am using 98 & IE5.5
>
> Thanks, Kelly
>

Roger,

Roger Roelofs                          Phone 616 574-0480 x246
Datacomp Appraisal Services            Fax   616 574-0486
3215 Eaglecrest Drive, NE  Suite 100   email rer@xxxxxxxxxxxxxxx
Grand Rapids, MI  49525-4593           web   www.datacompusa.com