登录时打开弹出窗口 [英] Open popup at log in

查看:135
本文介绍了登录时打开弹出窗口的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

登录后我想在新窗口中打开一个弹出页面,我希望主页面重定向到我的主页。我怎样才能做到这一点?如何从后面的代码中打开弹出窗口?

解决方案

1。要打开弹出窗口:

  Dim  queryString  As  字符串 =   test.aspx 
Dim newWin As String = window.open('& queryString& ');
ClientScript.RegisterStartupScript( Me GetType (), pop,newWin, True



2.重定向:

 Response.Redirect(  home.aspx


 window.location.href =   Home; 
window.open(' Yourpage' ' _ blank');







第一个代码会将您的页面重定向到home.n第二个代码将在新的浏览器选项卡中打开新页面。


After login I want to open a web page as a popup in a new window and I want the main page to redirect to my home page. How can I do this? How can I open the pop up from code behind?

解决方案

1. To open popup:

Dim queryString As String = "test.aspx" 
Dim newWin As String = "window.open('" & queryString & "');"
ClientScript.RegisterStartupScript(Me.GetType(), "pop", newWin, True)


2. To redirect:

Response.Redirect("home.aspx")


window.location.href = "Home";
  window.open('Yourpage', '_blank');




first code will redirect ur page to home.n second code will open new page in new browser tab..


这篇关于登录时打开弹出窗口的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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