如何在Javascript中重定向到我的应用程序中的页面 [英] How Do I Redirect To A Page In My Application In Javascript

查看:85
本文介绍了如何在Javascript中重定向到我的应用程序中的页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述




我想我正在阻止。



我正在运行一个asp.net应用程序而我使用Jquery在Web服务完成时将值传递给Web服务它回发了一个值,我创建了一个变量来保存从Web服务收到的值,我想重定向到我的应用程序中的页面并使用变量作为查询字符串



请你帮助

Hi
I think i am having a block.

I am running an asp.net application and i used Jquery to pass values to a web service when the web service completes it posts back a value for the, I have created a variable to hold the value received from the web service and i would like to redirect to a page in my application and use the variable as the query string

Please could you assist

推荐答案

function redirect(querystring){

 var url = "http://www.newlocation.com"

 if(querystring && querystring.length)

 url = url+querystring;

 window.location=url ;

}


这篇关于如何在Javascript中重定向到我的应用程序中的页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆