分层导航的做法

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<script language="javascript" type="text/javascript" src="jquery-1.4.2.min.js"></script>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title>
<style>
#apDiv1 {
    position: fixed;/*fixed;left:auto;top:auto用来实现悬浮的效果*/
    left: auto;
    top: auto;
    bottom: auto;
    width: 237px;
    height: auto;
    z-index: 2;
    margin-top: -8px;
    margin-left: 40px;
    text-align: center;
    font-size: 16px;
    font-family: "黑体";
    color: #965D28;
    background-image: url(../img/bg.png);
}
#menu {
    display: none;
}
.daohang div {
    height: 30px;
    z-index: 2;
    margin: 0 auto;
    text-align: center;
    padding-top: 5px;
    overflow: hidden;
    padding-top: 10px;
    color: 965D28;
}
.daohang div:hover {
    height: 30px;
    z-index: 2;
    margin: 0 auto;
    background-image: url(../img/menu-hover.png);
    text-align: center;
    overflow: visible;
    color: #fff;
}
.daohang li {
    margin-left: 237px;
    list-style-type: none;
    background-color: #D3A23A;
    width: 160px;
    line-height: 30px;
    color: #422B1D;
    position: relative;
    top: -40px;
    background-image: url(../img/bg.jpg);
    border: solid thin;
    border-color: #965D28;
    z-index: 1;
}
.daohang li:hover {
    margin-left: 237px;
    list-style-type: none;
    background-color: #D3A23A;
    width: 160px;
    line-height: 50px;
    color: #fff;
    position: relative;
    top: -40px;
    border: solid thin;
    border-color: #965D28;
    background-image: url(../img/bg.png);
    z-index: 1;
}
.daohang a:link, a:visited {
    text-decoration: none;
    color: #965D28;
}
.daohang a:hover {
    text-decoration: none;
    color: #fff;
}
</style>
</head>

<body>
<script>   
function menuvisible() 
{   
    $("nav").slideToggle(1500);/*开关*/  
}    
</script>
<div id="apDiv1" > <img src="n0.jpg" width="80" />
  <nav id="menu">
    <div class="daohang" style="  <a href="index.html">
      <div style="  color:#fff">首页 </div>
      </a> <a href="about us.html" target="_blank">
      <div>关于我们 </div>
      </a> <a href="services.html" target="_blank">
      <div>咖啡文化 </div>
      </a> <a href="price list.html" target="_blank">
      <div>价格清单 </div>
      </a> <a href="contact.html" target="_blank">
      <div>联系我们 </div>
      </a> </div>
  </nav>
  <div style="color:#fff;line-height:35px; background-image:url(img/menu-hover.png); border:solid medium #965D28; margin-top:3px;" οnclick="menuvisible()">
    <input style="color:#fff; border:none; width:100%;  font-family:'黑体'; font-size:16px; height:100%; line-height:35px;"type="button" value="<--MENU-->" />
  </div>
  <div style="background-image:url(img/bg.png)"><a href="#top"style="text-decoration:none; color:#965D28;line-height:30px;">TOP </a> </div>
</div>
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
<br />
咖啡
</body>
</html>

转载于:https://www.cnblogs.com/wuxiaochao/p/6061547.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
Webview2 分层是一种将Webview2控件拆解成不同的层次结构的方法。通过将Webview2控件分成不同的层次,可以实现更好的可定制性和控制性。 Webview2 分层通常包括三个层次:应用层、Webview2 控件层和渲染层。 应用层是最高层,负责管理和控制整个应用程序的逻辑。在应用层,我们可以根据需求添加自定义的功能和交互,例如处理用户输入、响应事件等。 Webview2 控件层是 Webview2 控件的核心部分,负责加载和展示网页内容。在这一层,我们可以对网页进行基本的操作,例如导航到指定URL、获取网页的标题、注入JavaScript等。 渲染层是Webview2控件的底层,主要负责将网页内容进行渲染并显示在屏幕上。渲染层使用Chromium内核来处理网页渲染,因此具有强大的渲染功能和性能优势。 通过将Webview2控件分成不同的层次,我们可以更好地进行定制和控制。例如,在应用层可以添加自定义的UI元素或逻辑,使Webview2控件与应用程序更好地融合;在Webview2控件层可以实现页面导航或与JavaScript的交互;在渲染层可以对页面进行更细粒度的控制,例如修改页面的样式或拦截网络请求。 总之,Webview2 分层是一种将Webview2控件拆解成不同层次结构的方法,通过这种方式可以实现更好的定制性和控制性,使Webview2控件更好地与应用程序整合,并满足不同的开发需求。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值