![]() |
|
#1
|
||||
|
||||
Review my JavascriptI have never taken the trouble to figure out Javascript, so this attempt reminds me of the days I used to hack together parts of perl scripts without really knowing what I was doing
Here's what I want to do, a user clicks on a checkbox and the action writes/appends the (option) ID to a cookie. Details about the cookie: Name: compare Example cookie value: 23|5|90 Cookie expires: session only The javascript I have put together: Read the cookie Code:
Write the cookie Code:
Adding the ID to the cookie: Code:
If you can go through the code/script and suggest corrections, I will appreciate it. Ultimately, I just want them to work securely. __________________
J de Silva Learning Journal | GIDForums™ | GIDNetwork™ | GIDWebhosts™ | GIDSearch™ |
|
#2
|
||||
|
||||
Re: Review my JavascriptSince starting this thread, I have refined the script further. Finally, I think I'm getting somewhere with JavaScript!
Here's an excerpt of the script that I uploaded today... Code:
If you can think of anything that makes this script more secure, anything at all, please do not hesitate to reply with your comment(s). Meanwhile, I will continue my work on the "comparison" web pages to go with this script. __________________
J de Silva Learning Journal | GIDForums™ | GIDNetwork™ | GIDWebhosts™ | GIDSearch™ |
Recent GIDBlog
Last Week of IA Training by crystalattice
| Thread Tools | Search this Thread |
| Rate This Thread | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| We're looking for JavaScript codes / mini tutorials. | JdS | Web Design Forum | 7 | 31-Mar-2008 23:25 |
| An Introduction to Javascript | JasonMichael | Web Design Forum | 2 | 24-Oct-2004 10:19 |
| JavaScript Tutorial Part 1 | pcxgamer | Web Design Forum | 2 | 01-Dec-2003 09:16 |
| Before posting a web host review - PLEASE READ | JdS | Web Host Review Forum | 0 | 16-Oct-2003 09:28 |
| This JavaScript doesn't work on Mozilla. | JdS | Web Design Forum | 8 | 02-Jul-2003 14:08 |
Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The