Several ways to asp.net nested pages __.net

Source: Internet
Author: User
1, #include tisp => aspx page, aspx cannot be nested because a page can have only one "page" instruction. Code: <!--#include file= "/home/default.aspx"--> 2, IFRAME (adaptive screen height, height 100% display (without JS) Tips => must be removed <! DOCTYPE html> in HTML, otherwise height 100% invalid Code: <iframe id= "Ifrmain" name= "Ifrmain" frameborder= "0" scrolling= "yes" src= "/ Home/default.aspx "style=" Height:100%;visibility:inherit; width:100%;z-index:1; " ></iframe> 3, Response.WriteFile () Tips => asp.net "response.writefile" method, limited to static file Code: <%response.wri Tefile ("/home/default.html");%> if the website domain name is www.chinalzw.com, the first page path is/home/default.aspx, the visit time displays is the www.chinalzw.com/

Home/default.aspx now want to visit the home page when only display domain name (www.chinalzw.com), how to do.

Knowledge point: Want to achieve home page only show www.chinalzw.com, then the first page must be in the root directory; This is a good idea. Method 1, create a Default.aspx Code in the root directory: <%@ Page language= "C #" autoeventwireup= "true" codebehind= "Default.aspx.cs" Inherits= "ICM. Web.default "%> <! doctype>  


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.