用框架网页,和mvc不mvc无关。google frameset

解决方案 »

  1.   


    这个是母版页这个是左边的菜单这个是上边的菜单
    @Html.Partial("~/Views/Shared/_TopMenu.cshtml")
    @Html.Partial("~/Views/Shared/_LeftMenu.cshtml")
    这两个是分别在Shared控制器里嵌套的两个视图,上左菜单
    然后你自己新建视图引用母版页,新建视图上面的html代码就会出现在@RenderBody()的位置
      

  2.   


    第一步新建 MasterPage. master 母版页<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">
      <tr>
      <!--左边菜单栏开始-->
        <td class="style1" valign="top">

            <asp:TreeView ID="TreeView1" runat="server" DataSourceID="XmlDataSource1" 
                ImageSet="Faq">
                <ParentNodeStyle Font-Bold="False" />
                <HoverNodeStyle Font-Underline="True" ForeColor="Purple" />
                <SelectedNodeStyle Font-Underline="True" HorizontalPadding="0px" 
                    VerticalPadding="0px" />
                <DataBindings>
                    <asp:TreeNodeBinding DataMember="siteMapNode" NavigateUrlField="url" 
                        TextField="title" />
                    <asp:TreeNodeBinding DataMember="siteMapNode" NavigateUrlField="url" 
                        TextField="title" />
                    <asp:TreeNodeBinding DataMember="siteMapNode" NavigateUrlField="url" 
                        TextField="title" />
                </DataBindings>
                <NodeStyle Font-Names="Tahoma" Font-Size="8pt" ForeColor="DarkBlue" 
                    HorizontalPadding="5px" NodeSpacing="0px" VerticalPadding="0px" />
            </asp:TreeView>

            <asp:XmlDataSource ID="XmlDataSource1" runat="server" DataFile="~/XMLFile.xml">
            </asp:XmlDataSource>       
    </td>
    <!--右边主要内容开始-->

        <td valign="top">
        <table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td>
            <asp:ContentPlaceHolder ID="cphContent" runat="server">
            
            </asp:ContentPlaceHolder>
        </td>
      </tr>
    </table>
    </td>
      </tr>
    </table>
    </div>
    <!--网站底部开始-->
    <div align="center">
    <div style="text-align: left; background-color: #8ed055; font-size: 10pt;width: 100%;height:9px;">&nbsp;</div>
    <br>
    <a href="#" class="bottom">公司简介</a> &nbsp; &nbsp; <a href="#" class="bottom">诚征英才</a>
        &nbsp;&nbsp; <a href="#" class="bottom">网站联盟</a> &nbsp;&nbsp; <a href="#" class="bottom">店中店招商</a>
        &nbsp;&nbsp; <a href="#" class="bottom">交易条款</a>
    </div>
    第二步 写个 ~/XMLFile.xml 文件
    <?xml version="1.0" encoding="utf-8" ?>
    <!--<siteMap xmlns="http://schemas.microsoft.com/AspNet/SiteMap-File-1.0" >-->
      <siteMapNode url="" title="武汉医舟"  description="">
        <siteMapNode url="" title="首页" description="">
          <siteMapNode url="News.aspx" title="行业新闻" description=""/>
          <siteMapNode url="Law.aspx" title="在线法规" description=""/>
          <siteMapNode url="Trends.aspx" title="企业动态" description=""/>
        </siteMapNode>    <siteMapNode url="" title="数据管理" description="">
          <siteMapNode url="Stock.aspx" title="进货分析" description=""/>
          <siteMapNode url="Sales.aspx" title="销售分析" description=""/>
          <siteMapNode url="Stores.aspx" title="库存分析" description=""/>
        </siteMapNode>    <siteMapNode url="" title="诚信管理" description="">
          <siteMapNode url="Rank.aspx" title="诚信排行" description=""/>
          <siteMapNode url="Crddits.aspx" title="信用评测" description=""/>
          <siteMapNode url="Rules.aspx" title="评测准则" description=""/>
        </siteMapNode>    <siteMapNode url="" title="服务管理" description="">
          <siteMapNode url="Order.aspx" title="订货管理" description=""/>
          <siteMapNode url="UpDrug.aspx" title="药品上架" description=""/>
          <siteMapNode url="UpDrugType.aspx" title="种类上传" description=""/>
        </siteMapNode>    <siteMapNode url="" title="两网建设" description="">
          <siteMapNode url="Varietie.aspx" title="品种档案" description=""/>
          <siteMapNode url="CheckUp.aspx" title="检测上报" description=""/>
          <siteMapNode url="Knowledge.aspx" title="用药知识" description=""/>
        </siteMapNode>    <siteMapNode url="" title="系统管理" description="">
          <siteMapNode url="Organizations.aspx" title="组织机构" description=""/>
          <siteMapNode url="pwdChange.aspx" title="修改密码" description=""/>
          <siteMapNode url="UsersMessage.aspx" title="用户管理" description=""/>
          <siteMapNode url="NoticeMessage.aspx" title="公文管理" description=""/>
          <!--<siteMapNode url="AddType.aspx" title="增加类型" description=""/>-->
          <siteMapNode url="Power.aspx" title="权限管理" description=""/>
        </siteMapNode>  </siteMapNode><!--</siteMap>-->第3步 新建页面 时选择模板也,就可以实现你说的 需求了
      

  3.   

    跟mvc没半毛钱关系,你应该是想要个后台管理界面吧,让你们美工都可以跟你做一个
      

  4.   

    jquery ui 或者Dwz 页面的开源框架 都能实现  和MVC没关系
      

  5.   

    第一种解决方案 iframe  (谷歌百度一下,马上就会了)这个跟使用何种技术无关。第二种解决方案,教你一个最简单的办法,微软VS提供了mvc Demo,打开你的VS,新建一个mvc项目,这时自动生成了一个mvc项目,点击上面菜单,“主页”,“关于”,这不是切换吗~  搞清楚里面代码思路,竖向不就洒洒水OK了~