Go Back   CodingForums.com > :: Client side development > JavaScript programming > Ajax and Design

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 03-22-2007, 05:17 PM   PM User | #1
nexosis
Regular Coder

 
nexosis's Avatar
 
Join Date: Dec 2006
Posts: 120
Thanks: 0
Thanked 0 Times in 0 Posts
nexosis can only hope to improve
ajax: stop and continue redirect

How do we stop and continue redirecting? example is when logging in codingforums.

Is this possible with AJAX?
__________________

progress: HTML: 100% > CSS: 90% > Javascript: 55% > Php:10%
Want an avatar like mine? it's free! just pm me.
nexosis is offline   Reply With Quote
Old 03-22-2007, 10:01 PM   PM User | #2
carlitos_way
New Coder

 
Join Date: Mar 2007
Location: italy
Posts: 94
Thanks: 1
Thanked 1 Time in 1 Post
carlitos_way is an unknown quantity at this point
Quote:
Originally Posted by nexosis View Post
How do we stop and continue redirecting? example is when logging in codingforums.

Is this possible with AJAX?
login of codingforums is without AJAX:
you're in page A, compile the form with your usern and passw, press submit.
so you're redirected to page B, which checks for your authentication. if succeeds, wait a few seconds and then send you back to A. if not, it gives you an error etc...
it's something like this:
Code:
	if authentication == OK
	then
		<script>
			function doRedirect() {
				location.href = "the page where you come from";
			}

			window.setTimeout("doRedirect()", 4000);
		</script>
	else
		go to error page
		etc..
with AJAX:
you are on page A, you compile the form and press submit, AJAX with Javascript contacts the server and look if you can be authenticated or not, and then tells you, always staying on page A.

so, the example you asked for is without AJAX
carlitos_way is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

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

Forum Jump


All times are GMT +1. The time now is 05:06 PM.


Advertisement
Log in to turn off these ads.