简体   繁体   English

如何制作一个弹出式面板,在.aspx页面中为调查加载网页?

[英]How to make a popup panel that loads a webpage for like a survey in a .aspx page?

What I'm trying to accomplish is this. 我想要完成的是这个。 I want it to be so that when the user clicks a button, a pop up comes up and allows them to complete, say, the survey. 我希望它是这样的,当用户点击按钮时,会弹出一个弹出窗口并允许他们完成调查。 However, I do NOT want it to be a popup window, just something like in the image. 但是,我不希望它成为一个弹出窗口,就像在图像中一样。 Additionally, the pop up needs to be able to have a webpage embedded in it, because the survey is a page in itself. 此外,弹出窗口需要能够嵌入网页,因为调查本身就是一个页​​面。 So basically, instead of it being that when the user clicks the button they are redirected, I want a pop up (not a popup window) to appear with the page in it. 所以基本上,当用户点击按钮重定向时,我希望弹出窗口(不是弹出窗口)与页面一起出现。 What I have used so far is iframe in a panel, but I feel there must be a better and more stable way, than using frames. 我到目前为止使用的是面板中的iframe,但我觉得必须有比使用框架更好更稳定的方法。 Can anyone suggest a better method? 有谁能建议更好的方法? Sorry about my terminology, if have no idea what this is called, I'm new to .ASP NET wed development. 对我的术语感到抱歉,如果不知道这叫什么,我是.ASP NET wed开发的新手。 Here is the code (the button changes visible=”False” to true): 这是代码(按钮将visible =“False”改为true):

   <asp:Panel CssClass="BlowItUp" ID="Panel1" runat="server" 
            Visible="False" >

         <iframe src="http://10.0.0.1/start.htm" style="width:100%; height:100%; top:0px;" />


      </asp:Panel>

The CSS if it matters: CSS如果重要:

.BlowItUp
{
    position:absolute;
    width:80%;
    height:90%;
    z-index:300;    
    right:10%;
    top:5%;
    padding:0px;
}

在此输入图像描述

Unless you have control over the "inner" page, I think a frame is the best you're going to manage. 除非您可以控制“内部”页面,否则我认为框架是您要管理的最佳框架。 Otherwise the inner page will seek to navigate to another page and you'll lose your "framing". 否则内页将寻求导航到另一个页面,你将失去你的“框架”。

The one thing I would suggest though is a different popup panel. 我建议的一件事是一个不同的弹出式面板。 Say jQuery UI Dialog ? jQuery UI对话框

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM