RSS

Different ways to redirect URL using Javascript

02 Mar

Hi folks,

Here is some useful information about how will we redirect the URL to JSP page using Javascript

1. <script language=”javascript” type=”text/javascript”>
window.location.href=”login.jsp?backurl=”+window.location.href;
</script>

2. <script language=”javascript”>
window.history.back(-1);
</script>

3. <script language=”javascript”>
window.navigate(”top.jsp”);
</script>

4. <script language=”JavaScript”>
self.location=”top.htm”;
</script>

5. <script language=”javascript”>
alert(”Access Violation”);
top.location=”error.jsp”;
</script>

Hope this will save your time.

Happy Learning!.

Get glued to know more updates.

Have a nice day:-)

Advertisements
 
Leave a comment

Posted by on March 2, 2013 in Uncategorized

 

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: