»
 

Go Back   ResellerRatings Store Ratings > ResellerRatings Forums > Tech Support

Reply
 
LinkBack Thread Tools Display Modes
Old 01-07-2004, 01:46 PM   #1 (permalink)
Registered User
 
Join Date: Jan 2004
Location: UK Manchester
Posts: 24
Therave is on a distinguished road
Kids Jave help with the (if) string

I am using the below * part of script *

} if (usercode==115604600&&passcode==115604600);}

window.location=password+".htm"}

else
{
alert("password/username wrong")}

where the 115604600 are encrypted for user name and password

this works fine if only one user....

How do I add a string that will allow the if function to check against a second user and password ?

full origional script can be seen at http://www.dynamicdrive.com/dynamicindex9/password.htm

I want to use this but have it check more that one name and password

any one help?? or tell me a better script to check users and passwords before sending them to the page that relates to them?

Thanks the rave

Therave is offline   Reply With Quote
Old 01-07-2004, 04:47 PM   #2 (permalink)
Registered User
 
Join Date: Jan 2004
Location: UK Manchester
Posts: 24
Therave is on a distinguished road
well got no help but for anyone reading

I managed to find this http://www.geocities.com/SiliconVall...w/conteng.html

and it worked a treat... however if there is any people with more knowledge than me a novice could look at the .class files and tell me if there is anything dodgg written in the scripts that might be sending information to places other than where ist intended.

appreciated in advance.
Therave is offline   Reply With Quote
Old 01-08-2004, 06:45 PM   #3 (permalink)
Registered User
 
Join Date: Sep 2002
Posts: 265
Creosote is on a distinguished road
I don't understand if this is for JavaScript or Java. Your first link is js, and the second looks likes its for a Java Applet. I don't use javascript much, but for regular java, you make a method has is called with two parameters passed in, and you check those variables against your values.
Creosote is offline   Reply With Quote
Old 01-08-2004, 06:53 PM   #4 (permalink)
Registered User
 
Join Date: Jan 2004
Location: UK Manchester
Posts: 24
Therave is on a distinguished road
got the crap above sorted... just need to work on how .htaccess works so anyone accessing a folder using a direct link cant have access unless they have come from my login page

can anyone help with .htaccess

have a folder called /private with a login page that directs to subfolders in private eg /private/images

I want any folder in the /private/images folder to return an error on page unless its come from the login page

am i making sense???

the rave
Therave is offline   Reply With Quote
Old 01-12-2004, 09:50 AM   #5 (permalink)
Registered User
 
Join Date: Oct 2001
Location: New Hampshire, USA
Posts: 604
ctaylor is on a distinguished road
Don't ask me how to do this, but have you considered having a successful login create an object with a property value you can check prior to opening a linked web page? If the individual browsing the web does not log in, then they would not have an instance of the "LoginSuccessfullyAuthenticated" object to check prior to loading a web page. You could store this object in memory and know that upon reboot it would be destroyed. Alternately you could build in a "time bomb" of sorts into the instance of the object that would destroy the "LoginSuccessfullyAuthenticated" object after a predetermined time interval.

Another method (less sophisticated) would be to create a cookie upon a successful login. This cookie could then be checked prior to loading specific web pages stored upon your site.

Hope this helps.

Last edited by ctaylor; 01-12-2004 at 09:52 AM.
ctaylor is offline   Reply With Quote
Reply




Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Most Active Discussions

Recent Discussions

All times are GMT -6. The time now is 12:46 PM.