Home > front end >  All men come on, river's lake emergency!
All men come on, river's lake emergency!

Time:09-16

this is my current code of rendering (figure 1), if you want to achieve the effect of figure 2 code should be how to write (temporarily don't consider using pseudo class beautification), (point to the left of the navigation key, the right can present corresponding third-party web pages,) will be appreciated, and if the man can completion code
Figure 1

CodePudding user response:

 




<meta charset="utf-8" & gt;
No title documents & lt;/title> <br/><style> <br/>* {<br/><br/>margin: 0; <br/>padding: 0; <br/>list-style: none; <br/>Color: # F0E5E5; <br/><br/>} <br/><br/>HTML, <br/>Body {<br/>height: 100%; <br/>} <br/><br/>. Biankuang {<br/>width: 100%; <br/>height: 100%; <br/>display: flex; <br/>} <br/><br/>The nav {<br/>Background: # 3 d3939; <br/>Width: 160 px; <br/>} <br/><br/>. The content {<br/>flex: 1; <br/>} <br/><br/>. The content li {<br/>position: relative; <br/>width: 100%; <br/>height: 100%; <br/>display: none; <br/>} <br/><br/>. The content li. Active {<br/>display: block; <br/>} <br/><br/>. The content li iframe {<br/>position: absolute; <br/>width: 100%; <br/>height: 100%; <br/>} <br/><br/>. Biankuang. Nav li {<br/>height: 50px; <br/>Width: 150 px; <br/>Border: # 4 px solid CCC; <br/>float: left; <br/>margin: 0; <br/>Padding: 1; <br/>text-align: center; <br/>The line - height: 3; <br/>} <br/>. Biankuang. Nav li. Active {<br/>Border - color: # E23131; <br/><br/>} <br/></style> <br/></head> <br/><br/><body> <br/><Div & gt; <br/><Ul & gt; <br/><Li> Baidu & lt;/li> <br/><Li> CSDN</li> <br/><Li> Baidu & lt;/li> <br/><Li> CSDN</li> <br/><Li> Baidu & lt;/li> <br/><Li> CSDN</li> <br/></ul> <br/><Ul & gt; <br/><Li> <br/><iframe SRC="http://www.baidu.com/" frameborder="0" & gt; </iframe> <br/></li> <br/><Li> <br/><iframe SRC="https://bbs.csdn.net/forums/WebDevelop" frameborder="0" & gt; </iframe> <br/></li> <br/><Li> <br/><iframe SRC="http://www.baidu.com/" frameborder="0" & gt; </iframe> <br/></li> <br/><Li> <br/><iframe SRC="https://bbs.csdn.net/forums/WebDevelop" frameborder="0" & gt; </iframe> <br/></li> <br/><Li> <br/><iframe SRC="http://www.baidu.com/" frameborder="0" & gt; </iframe> <br/></li> <br/><Li> <br/><iframe SRC="https://bbs.csdn.net/forums/WebDevelop" frameborder="0" & gt; </iframe> <br/></li> <br/></ul> <br/></div> <br/><script> <br/>Const navs=document. QuerySelectorAll (' nav li ') <br/>Const contents=document. QuerySelectorAll (' content li ') <br/>Navs. ForEach ((e, index)=& gt; {<br/>E.o nclick=()=& gt; {<br/>TAB (index); <br/>} <br/>}) <br/>The function TAB (index) {<br/>Navs. ForEach ((e, I)=& gt; {<br/>If (index===I) {<br/>E.c. with our fabrication: lassName='active' <br/>} else {<br/>E.c. with our fabrication: lassName='<br/>} <br/>}) <br/>Contents. ForEach ((e, I)=& gt; {<br/>If (index===I) {<br/>E.c. with our fabrication: lassName='active' <br/>} else {<br/>E.c. with our fabrication: lassName='<br/>} <br/>}) <br/>} <br/>TAB (0); <br/></script> <br/></body> <br/><br/></html> <br/></pre><p class="article - content rp"> CodePudding user response: </p><fieldset> <legend> 1/f, reference wind 灬 cloud response: <legend> <blockquote> <pre> <br/><! Doctype html> <br/><Html> <br/><br/><head> <br/><meta charset="utf-8" & gt; <br/><title> No title documents & lt;/title> <br/><style> <br/>* {<br/><br/>margin: 0; <br/>padding: 0; <br/>list-style: none; <br/>Color: # F0E5E5; <br/><br/>} <br/><br/>HTML, <br/>Body {<br/>height: 100%; <br/>} <br/><br/>. Biankuang {<br/>width: 100%; <br/>height: 100%; <br/>display: flex; <br/>} <br/><br/>The nav {<br/>Background: # 3 d3939; <br/>Width: 160 px; <br/>} <br/><br/>. The content {<br/>flex: 1; <br/>} <br/><br/>. The content li {<br/>position: relative; <br/>width: 100%; <br/>height: 100%; <br/>display: none; <br/>} <br/><br/>. The content li. Active {<br/>display: block; <br/>} <br/><br/>. The content li iframe {<br/>position: absolute; <br/>width: 100%; <br/>height: 100%; <br/>} <br/><br/>. Biankuang. Nav li {<br/>height: 50px; <br/>Width: 150 px; <br/>Border: # 4 px solid CCC; <br/>float: left; <br/>margin: 0; <br/>Padding: 1; <br/>text-align: center; <br/>The line - height: 3; <br/>} <br/>. Biankuang. Nav li. Active {<br/>Border - color: # E23131; <br/><br/>} <br/></style> <br/></head> <br/><br/><body> <br/><Div & gt; <br/><Ul & gt; <br/><Li> Baidu & lt;/li> <br/><Li> CSDN</li> <br/><Li> Baidu & lt;/li> <br/><Li> CSDN</li> <br/><Li> Baidu & lt;/li> <br/><Li> CSDN</li> <br/></ul> <br/><Ul & gt; <br/><Li> <br/><iframe SRC="http://www.baidu.com/" frameborder="0" & gt; </iframe> <br/></li> <br/><Li> <br/><iframe SRC="https://bbs.csdn.net/forums/WebDevelop" frameborder="0" & gt; </iframe> <br/></li> <br/><Li> <br/><iframe SRC="http://www.baidu.com/" frameborder="0" & gt; </iframe> <br/></li> <br/><Li> <br/><nullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnull </div> <div class="th_page th_page_color"></div> <div class="umCopyright"> <p>Page link:<a href="/frontend/2027.html" target="_blank" style="color:#999">https//www.codepudding.com/frontend/2027.html</a></p> </div> <div class="detail-arr"> <div class="detail-arr-left">Prev:<a href='/frontend/2026.html'>Apache was launched, but is won't go to the computer itself</a></div> <div class="detail-arr-right">Next:<a href='/frontend/2028.html'>The use of el expression in the servlet output database, but does not display the database informati</a></div> </div> </div> </div> </div> </div> <div class="container th_top"> <div class="row"> <div class="col-md-12"> <div class="hot-tags neitags"> <ul> <li><i class="iconfont icon-x-tags"></i> Tags:  </li> <a href='/e/tags/?tagname=HTML5' target='_blank'>HTML5</a> </ul> </div> </div> </div> </div> <div class="container th_top"> <div class="row"> <div class="col-md-12"> <div class="xiangguan"> <ul class="msg msghead"> <li class="tbname">Related</li> </ul> <ul> </ul> </div> </div> </div> </div> <div class="container th_top"> <div class="row"> <div class="col-md-12"> <div class="flinks"> <ul> <li><i class="iconfont icon-x-tags"></i> Links:  </li> <li class="liflinks"><a target="_blank" href="/" title="CodePudding">CodePudding</a></li> </ul> </div> </div> </div> </div> <div class="footer"> <p><span style="font-size:16px;color:#666;font-weight: bold">About Us:</span>  <a href="https://www.codepudding.com/contact.html">Contact Us</a>      <a href="https://www.codepudding.com/service.html">Terms of Service</a>      <a href="https://www.codepudding.com/privacy.html"> Privacy Policy</a></p> <p class="foot_info">Copyright © 2010-2023,Powered By <a href="/" target="_blank">CodePudding</a> </p> </div> <script type="text/javascript" src="/skin/code/tianhu.js"></script> </body></html>