MarcP Posted December 17, 2006 Share Posted December 17, 2006 Good morning everyone I'm new to this forum and new to js and from what i've seen you people are wonderful.I've created some software and I'm trying to have it so that it will be fully functional for 30 days and then after that an alert box will pop up explaining that their time has expired. After the user clicks the "ok" button they will be redirected toa web page.I've tried the myDate function with no luckAny ideas?? Link to comment Share on other sites More sharing options...
Webworldx Posted December 17, 2006 Share Posted December 17, 2006 What type of "software" is this? I'm guessing it's more than just a small piece of javascript...? Link to comment Share on other sites More sharing options...
Beta Posted December 17, 2006 Share Posted December 17, 2006 Just add a cookie that expires in 30 days, then have the script check for it:p Have the cookies name and value encrypted so that the user cant cheat and make another one though...lol Link to comment Share on other sites More sharing options...
jesh Posted December 18, 2006 Share Posted December 18, 2006 Just add a cookie that expires in 30 days, then have the script check for it:p Have the cookies name and value encrypted so that the user cant cheat and make another one though...lolI'm guessing you're going to need some server-side code to accomplish this. If the encryption algorithm is done in javascript, anyone with a passing knowledge of javascript will be able to crack it. Link to comment Share on other sites More sharing options...
Beta Posted December 18, 2006 Share Posted December 18, 2006 I'm guessing you're going to need some server-side code to accomplish this. If the encryption algorithm is done in javascript, anyone with a passing knowledge of javascript will be able to crack it.Yes, but thats why you create two encryption functions that need keys to operate The keys are stored in a small database, then accessed via AJAX and used to decrypt the cookie and eval the main function :)Each encryption has a different key used to decrypt it Link to comment Share on other sites More sharing options...
jesh Posted December 18, 2006 Share Posted December 18, 2006 Yes, but thats why you create two encryption functions that need keys to operate The keys are stored in a small database, then accessed via AJAX and used to decrypt the cookie and eval the main function :)Each encryption has a different key used to decrypt it Ah, but to get the value from the database, you'll need server-side technologies - even using AJAX. Link to comment Share on other sites More sharing options...
Beta Posted December 18, 2006 Share Posted December 18, 2006 Ah, but to get the value from the database, you'll need server-side technologies - even using AJAX.Then use something other than a database Such as FF's globalStorage and IE's userData. Or you could have a webpage with keys and values that are auto-generated according to the user's persistent data value Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now