Web Forms :: Open A Pages In Iframe When Menu Items Are Clicked?
Mar 24, 2010I am trying to open a page in a iframe when a menu item is clicked. How can i do that..? I tried adding this code below but it doesn't work.
[Code]....
I am trying to open a page in a iframe when a menu item is clicked. How can i do that..? I tried adding this code below but it doesn't work.
[Code]....
in my application iam using an iframe, all pages are loaded on that iframe according to menu selection.My problem is that while timeout the login page is loaded inside the iframe.under the menu sectionHow can i overcome this?
View 1 Repliesi'm working with asp.net visual studio 2008 c#i'm using Menu and i added items . the first item has like sub-items ...now when i run the website, the Menu wont open the sub-items menu ... this is the code :
<li style="direction: rtl"> <asp:Menu ID="Menu2" runat="server" BackColor="WhiteSmoke" BorderColor="White" ForeColor="#6699FF" Font-Bold="True" Height="361px" Style="left: 2px; position: relative; top: -9px; background-color: #ffffff" Width="194px"> <Items> <asp:MenuItem
NavigateUrl="~/CourseSignUp.aspx" Text="קורסי גלישה" Value="קורסי גלישה"> <asp:MenuItem Text="קורס ילדים עד גיל 18" Value="קורס ילדים עד גיל 18"> <asp:MenuItem Text="קורסים בקיץ" Value="קורסים בקיץ" NavigateUrl="~/CourseSignUp.aspx"></asp:MenuItem> <asp:MenuItem Text="קורס ימי שישי" Value="קורס ימי שישי"></asp:MenuItem> <asp:MenuItem Text="קורסים בחגים" Value="קורסים בחגים"></asp:MenuItem> </asp:MenuItem> <asp:MenuItem Text="קורס מבוגרים" Value="קורס מבוגרים"> <asp:MenuItem Text="קורס ימי שישי" Value="קורס ימי שישי"></asp:MenuItem> </asp:MenuItem> </asp:MenuItem> <asp:MenuItem Text="שיעורים פרטיים" Value="New Item"> </asp:MenuItem> <asp:MenuItem NavigateUrl="~/Rents.aspx" Text="השכרות" Value="Rents"></asp:MenuItem> <asp:MenuItem Text="מידע לגולש המתחיל" Value="New Item"></asp:MenuItem> <asp:MenuItem Text="לי קים" Value="New Item"></asp:MenuItem> <asp:MenuItem Text="תחזיות" Value="New Item" NavigateUrl="~/Forecasts.aspx"></asp:MenuItem> <asp:MenuItem Text="מאמרים" Value="New Item"></asp:MenuItem> <asp:MenuItem Text="הסטורית גלישה" Value="New Item"></asp:MenuItem> </Items> </asp:Menu> </li>
Our website application needs to open other web sites Iframe.(Our application is web based tool to help high school children to analyze the websites. It has to show news websites to in one iframe and in rest of the page there will be questions related to the news website)
But since many websites use framekiller code, these sites take control of entire page. Is there any ternative way / solution to this problem?It is necessary to be able to open other sites in our website (in iframe or any alternate way), otherwise whole concept of our application will become void.
I have an asp.net page that contains an Iframe embedded with some data and a ImageButton. On ImageButton click event (server side) I have Response.Redirct:
Response.Redirect("results.aspx");
This always open the results.aspx in iframe. I want that results.aspx should always open in the parent window. I tried the following till now but none worked:
Response.Redirect("<script language='javascript'>self.parent.location='results.aspx';</script>");
Response.Redirect("javascript:parent.change_parent_url('results.aspx');");
..and also tried the options from [URL]
In my application users upload their word document and user has been given an option to preivew the uploaded document. Inorder to preview the document i put the following code in my page_load event
div1.InnerHtml = "<iframe name='iframe4' src='DocumentUuploaded/report.doc ' target='iframe4' frameborder='no' height='500' scrolling='no' width='800'></iframe>";
The problem is it is asking Do you want to open or save this file. How can i get rid of this dialouge box
Currently I have a menu control on my webform in ASP.Net 4.0 :
<div class="PNMenu">
<asp:SiteMapDataSource ID="PNSiteMap" runat="server" ShowStartingNode="false" />
<asp:Menu ID="PNMainMenu" runat="server" DataSourceID="PNSiteMap" RenderingMode="List" Orientation="Horizontal" CssClass="PN-PrimaryNavMenu" >
</asp:Menu>
</div>
I am trying to style the menu control to allow the menu items to float to the right of the container, however I am unable to do so as whenever I am styling the a, ul or li it keeps getting overidded by asp.net and floats everything left.
.PNMenu
{
clear:both;
[code]...
What I want is to show menu items Administrator or show user menu items.Show menu items using login...How I can do it with role provider, control menu and siteMap in masterpage?
View 1 Replieshow to align the menu bar with proper space
View 1 Repliesi open a iframe in a page, from that page opend in iframe, i want the page url.means one page mainpage.aspx have a iframe, that iframe open open a iframepage.aspx page.from the iframepage.aspx page's button click event i want to referesh the mainpage.aspx page.how can i do.
I'm using asp.net and css to style a master page with navigation at the top. I was hoping to add the login status control in as a menu item but it is not allowed. Can someone point me in the right direction? When I post my code on this forum do I have to include tags?
View 4 RepliesI want to display page in IFrame when you click on menu item. This is how i am writing the code for it.
[code]...
But its opening the page in new window instead of the given Target of Iframe.
How to achieve the below using frames in asp.net?
[URL] ....
The menu in the navigation bar is static.
I have placed an aspx menu control on my master page with orientation as Horizontal. Below is HTML markup.
HTML Code:
<asp:Menu ID="mnuMedChem" runat="server" Orientation="Horizontal" Width="100%" OnMenuItemClick="mnuMedChem_MenuItemClick">
<DynamicHoverStyle CssClass="DynamicHover" />
<DynamicMenuItemStyle CssClass="DynamicMenuItem" />
[Code]....
I have tried populating the menus from my database by using the
Code:
mnuMedChem.Items.Add
and
Code:
mnuMedChem.FindControl(value).ChildItems.Add
The menu items and the childs are populating correctly but then the menu is not being displayed on the menu control.
I need a help in creating a vertical oriented Menu control with dynamic url's set in there Navigate Url property.Also i need to set the menu items as enable/disable in two different modes say edit/new.
I have my webpage, left hand side contains Treeview, and Other Side contains IFrame,
View 6 RepliesI am using master pages standard theme is vs 2010, have few tabs and they all open different pages. wondering if any body knows how to change the colour of tab after the tab is clicked. will be useful to identify page for user.
View 2 RepliesI added a menu avigation control in my page and i did this:
<div style="background-color: Maroon">
<asp:Menu ID="Menu1" runat="server" Orientation="Horizontal" ForeColor="Black" Font-Bold="true"
BackColor="Chocolate">
<Items>
<asp:MenuItem Text="Home"></asp:MenuItem>
<asp:MenuItem Text="About Us"></asp:MenuItem>
<asp:MenuItem Text="Services"></asp:MenuItem>
<asp:MenuItem Text="Careers"></asp:MenuItem>
<asp:MenuItem Text="Contact Us"></asp:MenuItem>
</Items>
</asp:Menu>
</div>
but i cant give proper spacing between the menu items right now it is appearing like this: how to give proper spacing between the menu items them?
I'm trying to create an asp menu for a website. The site will have 2 levels of user Master users (which will have more options) and Sub users which will have limited menu options.
I was wonder does anyone knows if a way to hide menu items? I've tried google but I can't really find much.
Here's the Asp code
[Code]....
I have worked out how to hide the whole menu when the user is not logged in
MainMenu.Visible = false
i have a link button which contains url as command argument in gridview and a iframe which will load pdf file from path.so in link button click, can i show pdf file in to iframe?
View 1 RepliesI have an iframe inside that there is a linkbutton if i click it should open a new tab in that browser,or Unblockable POPup's. I cant change it into other controls like Hyperlink or <a> tag, coz i am doing an DB updation in that linkbutton click event also passing values in query string.
View 7 RepliesI have a ppt in a folder Rocky and i am doing something like this :
this.btnSmartQuoteTutorialVideo.OnClientClick = "OpenMaximizedWindow('Tutorials/Paoli/PaoliSmartQuoteTraining.ppt'); return false;";
i am using web.sitemap
i have an iframe in my page
i want that when i click a link from web.sitemap the page will open in iframe
how can i do this?
i want the whole mainmenupanel to be invisible after a LinkButton in second menupanel is chosen.
How can i realize this effectively? Which method can be used for this?
My problem temporarly is, that the page_init function overwrites the Visibility method of the mainmenupanel.
i used the code present in that page (CODE USED). The user can click all the categories displayed, and i need to know the id of the one that he clicked.
[URL]
In the case of the screenshot i need to know which is the id of the category "Excel", the one that i clicked.