Click to go to Forum Home Click to go to maXbimmer Home

Go Back   maXbimmer Forums > Misc > Off-topic
User Name
Password


Welcome to Maxbimmer.com!

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

Reply
 
Thread Tools Rate Thread Display Modes
Old 07-11-2005, 03:21 PM   #1
bmnorm
4th Gear Member
 
bmnorm's Avatar
 
Join Date: Jul 2002
Location: queensway
Posts: 602
Need help with java script



Hey guys,

I need some help with java script. I am using a validation form that validates credit card numbers. I got this form online so which means I am pretty basic with this stuff. I have gotten the form to work & I have implemented in to the site.

But I need the page to be redirected once the card is validated.

Anyways here is the script if anyone can help me. That would be great.

sorry guys, it looks like the script is too long.

if anyone has some time I can e mail it to you.

thanks


Last edited by bmnorm; 07-11-2005 at 03:31 PM.
bmnorm is offline   Reply With Quote
Old 07-12-2005, 12:25 AM   #2
Justin e36
---
 
Justin e36's Avatar
 
Join Date: May 2003
Location: etobicoke
Posts: 12,331
Send a message via ICQ to Justin e36 Send a message via AIM to Justin e36 Send a message via Yahoo to Justin e36
break it up into multiple posts.
Justin e36 is offline   Reply With Quote
Old 07-12-2005, 12:28 AM   #3
Justin e36
---
 
Justin e36's Avatar
 
Join Date: May 2003
Location: etobicoke
Posts: 12,331
Send a message via ICQ to Justin e36 Send a message via AIM to Justin e36 Send a message via Yahoo to Justin e36
also be sure to paste it in Advanced mode, and disable parsing.
Justin e36 is offline   Reply With Quote
Old 07-12-2005, 01:05 AM   #4
BigD
the misanthropist
 
BigD's Avatar
 
Join Date: May 2002
Location: a house
Posts: 6,177
When you're done validating, just say window.location = url; And make url a variable you populate with the appropriate site

Honestly though, this type of work should be done serverside. Otherwise it's insecure as hell. Javascript is clientside code and MUCH more voulnerable. You should do this with serverside scripting, my personal favourite and of our company is PHP. You forward the card number to a php page which does the checking on the server, and then redirects you to the appropriate next page based on the result (with header commands).

Good luck.
BigD is online now   Reply With Quote
Old 07-12-2005, 03:55 AM   #5
Betray
6th Gear Member
 
Join Date: Feb 2002
Location: Richmond Hill
Posts: 4,353
Send a message via ICQ to Betray Send a message via AIM to Betray Send a message via MSN to Betray
Quote:
Originally Posted by BigD
When you're done validating, just say window.location = url; And make url a variable you populate with the appropriate site

Honestly though, this type of work should be done serverside. Otherwise it's insecure as hell. Javascript is clientside code and MUCH more voulnerable. You should do this with serverside scripting, my personal favourite and of our company is PHP. You forward the card number to a php page which does the checking on the server, and then redirects you to the appropriate next page based on the result (with header commands).

Good luck.
good advice, and im almost sure its his for his homework.
Betray is offline   Reply With Quote
Old 07-12-2005, 12:26 PM   #6
bmnorm
4th Gear Member
 
bmnorm's Avatar
 
Join Date: Jul 2002
Location: queensway
Posts: 602
Thanks for the reply guys,

Here is the script.


All times are GMT -4. The time now is 08:53 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2015, Jelsoft Enterprises Ltd.
Maxbimmer Copyright 2001 - 2015