传奇游戏发布首页HTML代码
下面是一个游戏发布首页的HTML代码,包含标题、导航栏、游戏展示区和新闻区等基本元素。
<!DOCTYPE html><html lang="zh-CN"><head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>传奇游戏发布站 - 最新传奇私服信息平台</title>
<style>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
font-family: 'Microsoft YaHei', sans-serif;
}
body {
background-color: #f5f5f5;
color: #333;
line-height: 1.6;
}
.container {
width: 1200px;
max-width: 100%;
margin: 0 auto;
padding: 0 15px;
}
/* 头部样式 */
header {
background: linear-gradient(to right, #8b0000, #cc0000);
color: white;
padding: 20px 0;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}
.header-content {
display: flex;
justify-content: space-between;
align-items: center;
}
.logo {
font-size: 28px;
font-weight: bold;
text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}
.logo span {
color: #ffcc00;
}
nav ul {
display: flex;
list-style: none;
}
nav ul li {
margin-left: 20px;
}
nav ul li a {
color: white;
text-decoration: none;
font-weight: bold;
padding: 5px 10px;
border-radius: 4px;
transition: background 0.3s;
}
nav ul li a:hover {
background: rgba(255, 255, 255, 0.2);
}
/* 主标题样式 */
.main-title {
text-align: center;
margin: 30px 0;
padding: 20px;
background: white;
border-radius: 8px;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}
.main-title h1 {
color: #8b0000;
font-size: 36px;
margin-bottom: 10px;
}
.main-title p {
color: #666;
font-size: 18px;
}
/* 游戏展示区 */
.game-showcase {
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 20px;
margin-bottom: 40px;
}
.game-card {
background: white;
border-radius: 8px;
overflow: hidden;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
transition: transform 0.3s;
}
.game-card:hover {
transform: translateY(-5px);
}
.game-img {
height: 180px;
background-color: #8b0000;
display: flex;
align-items: center;
justify-content: center;
color: white;
font-weight: bold;
font-size: 20px;
}
.game-info {
padding: 15px;
}
.game-info h3 {
color: #8b0000;
margin-bottom: 10px;
}
.game-info p {
color: #666;
margin-bottom: 15px;
font-size: 14px;
}
.btn {
display: inline-block;
background: #cc0000;
color: white;
padding: 8px 15px;
border-radius: 4px;
text-decoration: none;
font-weight: bold;
transition: background 0.3s;
}
.btn:hover {
background: #8b0000;
}
/* 新闻区 */
.news-section {
background: white;
border-radius: 8px;
padding: 20px;
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
margin-bottom: 40px;
}
.section-title {
color: #8b0000;
border-bottom: 2px solid #ffcc00;
padding-bottom: 10px;
margin-bottom: 20px;
font-size: 24px;
}
.news-list {
display: grid;
gap: 15px;
}
.news-item {
display: flex;
border-bottom: 1px dashed #ddd;
padding-bottom: 15px;
}
.news-date {
background: #8b0000;
color: white;
padding: 5px 10px;
border-radius: 4px;
margin-right: 15px;
min-width: 90px;
text-align: center;
}
.news-content {
flex: 1;
}
.news-content h3 {
margin-bottom: 5px;
}
/* 页脚 */
footer {
background: #333;
color: white;
padding: 30px 0;
text-align: center;
}
.footer-content {
display: flex;
justify-content: space-between;
flex-wrap: wrap;
}
.footer-section {
flex: 1;
min-width: 300px;
margin-bottom: 20px;
}
.footer-section h3 {
color: #ffcc00;
margin-bottom: 15px;
}
.copyright {
margin-top: 20px;
padding-top: 20px;
border-top: 1px solid #555;
width: 100%;
}
/* 响应式设计 */
@media (max-width: 992px) {
.game-showcase {
grid-template-columns: repeat(2, 1fr);
}
}
@media (max-width: 768px) {
.header-content {
flex-direction: column;
text-align: center;
}
nav ul {
margin-top: 15px;
justify-content: center;
}
.game-showcase {
grid-template-columns: 1fr;
}
.footer-content {
flex-direction: column;
}
} </style></head><body>
<!-- 头部 -->
<header>
<div class="container header-content">
<div class="logo">传奇<span>发布站</span></div>
<nav>
<ul>
<li><a href="#">首页</a></li>
<li><a href="#">游戏列表</a></li>
<li><a href="#">开区信息</a></li>
<li><a href="#">游戏攻略</a></li>
<li><a href="#">关于我们</a></li>
</ul>
</nav>
</div>
</header>
<!-- 主内容区 -->
<main class="container">
<!-- 主标题 -->
<div class="main-title">
<h1>2023最新传奇私服发布平台</h1>
<p>每日更新最新开服信息,提供最全的传奇私服资讯</p>
</div>
<!-- 游戏展示区 -->
<h2 class="section-title">热门游戏推荐</h2>
<div class="game-showcase">
<div class="game-card">
<div class="game-img">冰雪传奇</div>
<div class="game-info">
<h3>冰雪单职业</h3>
<p>全新冰雪版本,高爆率,装备全靠打,上线即送VIP</p>
<a href="#" class="btn">开始游戏</a>
</div>
</div>
<div class="game-card">
<div class="game-img">复古传奇</div>
<div class="game-info">
<h3>1.76复古版</h3>
<p>经典1.76版本,原汁原味体验,重温青春记忆</p>
<a href="#" class="btn">开始游戏</a>
</div>
</div>
<div class="game-card">
<div class="game-img">合击传奇</div>
<div class="game-info">
<h3>合击版</h3>
<p>英雄合击,畅快战斗,体验全新技能组合玩法</p>
<a href="#" class="btn">开始游戏</a>
</div>
</div>
</div>
<!-- 新闻区 -->
<div class="news-section">
<h2 class="section-title">最新开服信息</h2>
<div class="news-list">
<div class="news-item">
<div class="news-date">09-15</div>
<div class="news-content">
<h3>【新服】"龙腾四海"今日14点火爆开区</h3>
<p>全新版本,万元豪礼,登录即送VIP10+无限元宝</p>
</div>
</div>
<div class="news-item">
<div class="news-date">09-14</div>
<div class="news-content">
<h3>【活动】"中秋庆典"限时活动开启</h3>
<p>中秋限定装备上线,月饼兑换稀有道具</p>
</div>
</div>
<div class="news-item">
<div class="news-date">09-12</div>
<div class="news-content">
<h3>【更新】V3.5版本全新内容上线</h3>
<p>新增地图、BOSS和装备,优化游戏体验</p>
</div>
</div>
</div>
</div>
</main>
<!-- 页脚 -->
<footer>
<div class="container footer-content">
<div class="footer-section">
<h3>关于我们</h3>
<p>提供最新最全的传奇私服信息,十年老站值得信赖</p>
</div>
<div class="footer-section">
<h3>联系我们</h3>
<p>QQ: 123456789</p>
<p>Email: contact@example.com</p>
</div>
<div class="footer-section">
<h3>友情链接</h3>
<p><a href="#" style="color: #ffcc00;">传奇资讯站</a></p>
<p><a href="#" style="color: #ffcc00;">游戏论坛</a></p>
</div>
<div class="copyright">
<p>© 2025 传奇发布站. 版权所有.</p>
</div>
</div>
</footer></body></html>页面说明
这个HTML页面包含以下主要部分:
顶部导航栏:包含网站logo和主导航菜单
主标题区域:突出显示网站主题"2025最新传奇私服发布平台"
热门游戏推荐区:以卡片形式展示三款热门传奇游戏
最新开服信息区:以新闻列表形式展示最新开服信息和活动
页脚区域:包含关于我们、联系方式和友情链接等信息
页面采用了响应式设计,可以在不同尺寸的设备上正常显示,配色以红色和金色为主,符合传奇游戏的主题风格。
您可以直接复制此代码到HTML文件中,在浏览器中打开即可查看效果。
<< 上一篇
网友留言(0 条)