开始学习asp.net

今天总结一下学习asp.net

  1. 建一个空网站,然后先引入 Modernizr,在引入 jQuery
  2. 然后添加主题,规划母版页面
  3. 下面一段就是一个标准的母版页
  4. 在本母版也,用来规划页面的页头,菜单位置,页面内容位置,还有页脚位置。
  5. <div id="PageWrapper"> <header> 页眉栏 </header> <nav> 菜单栏 </nav> <section id="MainContent"> <asp:ContentPlaceHolder ID="cpMainContent" runat="server"> </asp:ContentPlaceHolder> </section> <aside id=“AsideBar”> Aside bar goes here </aside> <footer> Footer Goes Here </footer> </div>
  6. 主题:
*

#PageWrapper
{
  width: 844px;
  background-color: #5487c0;
  margin: auto;
}

header
{

  background-image: url(Images/Header.jpg);
  width: 844px;
  height: 86px;
}


nav
{

  background-image: url(Images/MenuBackground.jpg);
  width: 827px;
  height: 36px;
  padding-top: 7px;
  padding-left: 17px;
}


.MainMenu
{
  /*
    The Menu gets a white border on all four sides.
  */
  border: 1px solid #999999;
  width: 814px;
  height: 19px;
  background-color: #555555;
}

  .MainMenu ul li
  {
    /*
    Gives the four menu items in the main menu a width of 200px each.
  */
    width: 200px;
  }

section#MainContent
{
  /*
    Defines the main content area. The #MainContent element has a minimum height of 500 pixels, but can grow if necessary.
    The font-size is 80% of its parent element, which in this case comes down to 80% of the font
    the user has specified as the default font in the browser.
  */
  font-size: 0.8em;
  width: 659px;
  border-left: 1px solid white;
  border-right: 2px solid white;
  float: left;
  background-color: #e1e1e1;
  min-height: 500px;
  padding: 10px;
}

aside#Sidebar
{
  /*
    The Sidebar is positioned to the right of the MainContent section. It gets the same font-size as the 
	#MainContent section and gets a background image called Sidebar.jpg. 
	To ensure the image is visible in (most) browsers on a small page, the element gets a minimum 
	height of 500px. This is ignored by IE 6.
  */
  font-size: 0.8em;
  color: White;
  background-image: url(Images/Sidebar.jpg);
  background-repeat: no-repeat;
  background-color: #7773A1;
  width: 142px;
  min-height: 500px;
  padding-top: 10px;
  padding-bottom: 10px;
  padding-left: 20px;
  float: left;
}

footer
{
  /*
    The footer is positioned below all other content (yet still within PageWrapper).
    clear: both is used to clear the impact of the float properties used for #MainContent and #Sidebar.
  */
  width: 844px;
  clear: both;
  height: 37px;
  background-color: #A8D5FE;
  color: White;
  text-align: center;
  font-size: 0.7em;
  font-weight: bold;
  line-height: 37px;
}

`

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值