<html>
<head>
	<title>WEB攻防平台</title>
	<link href="https://cdn.bootcss.com/font-awesome/4.7.0/css/font-awesome.min.css" rel="stylesheet">
	<style>
		body {
			background-color: #1f1f1f;
			color: #fff;
			font-family: Arial, sans-serif;
			font-size: 16px;
			margin: 0;
			padding: 0;
		}
		.container {
			max-width: 800px;
			margin: 0 auto;
			padding: 40px 20px;
		}
		.cd-side-navigation {
			position: fixed;
			top: 0;
			left: 0;
			height: 100%;
			background-color: #3f3f3f;
			z-index: 9999;
			overflow-y: auto;
			-webkit-transition: all 0.3s;
			transition: all 0.3s;
		}
		.cd-side-navigation ul {
			padding: 0;
			margin: 0;
			list-style: none;
		}
		.cd-side-navigation li {
			position: relative;
		}
		.cd-side-navigation li a {
			display: block;
			color: #fff;
			font-size: 20px;
			font-weight: bold;
			padding: 20px;
			text-decoration: none;
			-webkit-transition: all 0.3s;
			transition: all 0.3s;
		}
		.cd-side-navigation li a:hover {
			background-color: #2ecc71;
			color: #fff;
		}
		.cd-side-navigation li a.selected {
			background-color: #2ecc71;
			color: #fff;
		}
		.cd-side-navigation svg {
			fill: none;
			stroke: #fff;
			stroke-width: 2;
			stroke-linecap: square;
			stroke-miterlimit: 10;
			width: 24px;
			height: 24px;
			margin-right: 10px;
			vertical-align: middle;
		}
		.section-wrap {
			display: flex;
			flex-wrap: wrap;
			margin-top: 80px;
		}
		.section {
			flex-basis: 100%;
			padding: 40px;
			background-color: #2ecc71;
			color: #fff;
		}
		.section-1 {
			background-image: url('https://cdn.pixabay.com/photo/2015/12/08/00/30/fantasy-1088145_960_720.jpg');
			background-size: cover;
			background-position: center;
			text-align: center;
		}
		.cd-title {
			margin-top: 100px;
			margin-bottom: 0;
		}
		.cd-title h2 {
			font-size: 48px;
			margin-bottom: 20px;
		}
		.cd-title span {
			font-size: 24px;
		}
		.section-2 {
			background-color: #fff;
			color: #2ecc71;
		}
		.title {
			text-align: center;
			margin-bottom: 40px;
		}
		.tit {
			font-size: 36px;
			font-weight: bold;
			margin-bottom: 20px;
		}
		.section-1-1 {
			font-size: 18px;
			line-height: 1.5;
			margin-bottom: 40px;
		}
		.section-1-1 span {
			font-weight: bold;
			display: block;
			margin-bottom: 10px;
			margin-top: 20px;
		}
		.content {
			margin-top: 40px;
			text-align: center;
		}
		.content ul {
			padding: 0;
			margin: 0;
			list-style: none;
		}
		.content li {
			display: inline-block;
			margin-right: 10px;
		}
		.content li a {
			display: inline-block;
			padding: 10px;
			background-color: #2ecc71;
			color: #fff;
			text-decoration: none;
			border-radius: 5px;
			-webkit-transition: all 0.3s;
			transition: all 0.3s;
		}
		.content li a:hover {
			background-color: #27ae60;
		}
		.on {
			background-color: #fff;
			color: #2ecc71;
			border: 2px solid #2ecc71;
			border-radius: 5px;
			padding: 10px;
			margin-right: 10px;
			-webkit-transition: all 0.3s;
			transition: all 0.3s;
		}
		.on:hover {
			background-color: #2ecc71;
			color: #fff;
			border: 2px solid #fff;
		}
        .cen_right_top {
            margin-bottom: 20px;
        }
        .cen_right_top a {
            display: block;
            padding: 10px;
            color: #fff;
            font-size: 18px;
            text-align: center;
            background-color: #2ecc71;
            border-radius: 5px;
            margin-bottom: 20px;
            text-decoration: none;
            -webkit-transition: all 0.3s;
            transition: all 0.3s;
        }
        .cen_right_top a:hover {
            background-color: #27ae60;
        }
        .content ul {
            display: none;
        }
        .content ul li {
            margin-bottom: 10px;
        }
        .content ul li a {
            display: block;
            padding: 10px;
            color: #fff;
            font-size: 18px;
            text-align: center;
            background-color: #2ecc71;
            border-radius: 5px;
            text-decoration: none;
            -webkit-transition: all 0.3s;
            transition: all 0.3s;
        }
        .content ul li a:hover {
            background-color: #27ae60;
        }
        .on.active {
            background-color: #fff;
            color: #2ecc71;
            border: 2px solid #2ecc71;
            border-radius: 5px;
        }
        .on.active:hover {
            background-color: #2ecc71;
            color: #fff;
            border: 2px solid #fff;
        }
        .content.show ul {
            display: block;
        }
	</style>
</head>
<body>
	<nav class="cd-side-navigation">
	    <ul>
	        <li>
	            <a href="#" class="selected">
	                <svg class="nc-icon outline" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="24px" height="24px" viewBox="0 0 24 24"><g transform="translate(0, 0)"> <polygon fill="none" stroke="#fff" stroke-width="2" stroke-linecap="square" stroke-miterlimit="10" points="12,2 3,10 3,23 9,23 9,16 15,16 15,23 21,23 21,10 " stroke-linejoin="miter"></polygon> </g></svg>
	                WEB攻防平台
	            </a>
	        </li>
	    </ul>
	</nav>
<pre><code>&lt;div class=&quot;container&quot;&gt;
	&lt;section class=&quot;section-wrap&quot;&gt;
	    &lt;div class=&quot;section section-1&quot;&gt;
	        &lt;div class=&quot;cd-title&quot;&gt;
	            &lt;h2&gt;WEB攻防平台&lt;/h2&gt;
	            &lt;span&gt;平台演练环境均内部使用&lt;/span&gt;
	        &lt;/div&gt;
	    &lt;/div&gt;
	    &lt;div class=&quot;section section-2&quot;&gt;
	        &lt;div class=&quot;title&quot;&gt;
	            &lt;p class=&quot;tit&quot;&gt;注入系列&lt;/p&gt;
	            &lt;div class=&quot;section-1-1&quot;&gt;
	                &lt;span&gt;相关概念&lt;/span&gt;
	                &lt;p&gt;随作用。&lt;/p&gt;
	                &lt;div class=&quot;cen_right_top&quot;&gt;
	                    &lt;a href=&quot;#&quot; class=&quot;on active&quot; data-target=&quot;section-1-1-1&quot;&gt;模拟实战一&lt;/a&gt;
	                    &lt;div class=&quot;content show&quot; id=&quot;section-1-1-1&quot;&gt;
	                        &lt;ul&gt;
	                            &lt;li&gt;&lt;a href=&quot;http://192.168.1.5/&quot; title=&quot;网站入口&quot;&gt;Asp+access手工注入&lt;/a&gt;&lt;/li&gt;
	                        &lt;/ul&gt;
	                    &lt;/div&gt;
	                &lt;/div&gt;
	                &lt;div class=&quot;cen_right_top&quot;&gt;
	                    &lt;a href=&quot;#&quot; class=&quot;on&quot; data-target=&quot;section-1-1-2&quot;&gt;模拟实战二&lt;/a&gt;
	                    &lt;div class=&quot;content&quot; id=&quot;section-1-1-2&quot;&gt;
	                        &lt;ul&gt;
	                            &lt;li&gt;&lt;a href=&quot;http://192.168.1.5/&quot; title=&quot;网站入口&quot;&gt;Asp+access手工注入&lt;/a&gt;&lt;/li&gt;
	                        &lt;/ul&gt;
	                    &lt;/div&gt;
	                &lt;/div&gt;
	                &lt;div class=&quot;cen_right_top&quot;&gt;
	                    &lt;a href=&quot;#&quot; class=&quot;on&quot; data-target=&quot;section-1-1-3&quot;&gt;模拟实战三&lt;/a&gt;
	                    &lt;div class=&quot;content&quot; id=&quot;section-1-1-3&quot;&gt;
	                        &lt;ul&gt;
	                            &lt;li&gt;&lt;a href=&quot;http://192.168.1.5/&quot; title=&quot;网站入口&quot;&gt;Asp+access手工注入&lt;/a&gt;&lt;/li&gt;
	                        &lt;/ul&gt;
	                    &lt;/div&gt;
	                &lt;/div&gt;
	                &lt;div class=&quot;cen_right_top&quot;&gt;
	                    &lt;a href=&quot;#&quot; class=&quot;on&quot; data-target=&quot;section-1-1-4&quot;&gt;模拟实战四&lt;/a&gt;
	                    &lt;div class=&quot;content&quot; id=&quot;section-1-1-4&quot;&gt;
	                        &lt;ul&gt;
	                            &lt;li&gt;&lt;a href=&quot;http://192.168.1.5/&quot; title=&quot;网站入口&quot;&gt;Asp+access手工注入&lt;/a&gt;&lt;/li&gt;
	                        &lt;/ul&gt;
	                    &lt;/div&gt;
	                &lt;/div&gt;
	            &lt;/div&gt;
	        &lt;/div&gt;
	    &lt;/div&gt;
	&lt;/section&gt;
&lt;/div&gt;
&lt;script&gt;
    const onButtons = document.querySelectorAll('.on');
    onButtons.forEach(button =&gt; {
        button.addEventListener('click', function(e) {
            e.preventDefault();
            const targetId = this.getAttribute('data-target');
            onButtons.forEach(b =&gt; b.classList.remove('active'));
            this.classList.add('active');
            document.querySelectorAll('.content').forEach(c =&gt; c.classList.remove('show'));
            document.getElementById(targetId).classList.add('show');
        });
    });
&lt;/script&gt;
</code></pre>
</body>
</html>
魔幻感前端界面设计:WEB攻防平台案例

原文地址: https://www.cveoy.top/t/topic/l48o 著作权归作者所有。请勿转载和采集!

免费AI点我,无需注册和登录