每日60秒新闻早报单页文字版HTML源码

每日60秒新闻早报单页文字版的,这个很早就有了,最近有用户问我这个怎么实现,其实很简单的只是一个单页而已,这个是PHP版的会将头部图片缓存到本地然后在展示可防止接口信息泄露。

PHP接口源码

每日新闻早报.zip

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>
        body {
            font-family: Arial, sans-serif;
            margin: 0;
            padding: 0;
            display: flex;
            flex-direction: column;
            align-items: center;
        }
        .container {
            width: 90%;
            max-width: 800px;
            margin: 20px auto;
            padding: 20px;
            border-radius: 8px;
            box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
        }
        .header img {
            width: 100%;
            height: auto;
            border-radius: 8px;
        }
        h1 {
            text-align: center;
            margin: 20px 0;
        }
        ul {
            list-style-type: none;
            padding: 0;
        }
        li {
            background-color: #fff;
            padding: 10px;
            border-radius: 8px;
        }
        .weiyu {
            text-align: center;
            font-style: italic;
            margin-top: 20px;
        }
    </style>
</head>
<body>
    <div class="container">
        <div class="header">
            <img src="<?php echo $headImageFile; ?>">
        </div>
        <h1><?php echo $date; ?> 新闻早报</h1>
        <ul>
            <?php foreach ($news as $newsItem): ?>
                <li><?php echo $newsItem; ?></li>
            <?php endforeach; ?>
        </ul>
        <p class="weiyu"><?php echo $weiyu; ?></p>
    </div>
</body>
</html>
相关推荐
阿星AI工作室1 小时前
一个简单Demo彻底理解前后端怎么连的丨Figma + Supabase + Vercel
前端·人工智能
aircrushin2 小时前
一拍即传的平替,完全免费的实时照片墙!
前端
鹏北海4 小时前
JSBridge 原理详解
前端
孟健4 小时前
我的网站被黑了:一天灌入 227 万条垃圾数据,AI 写的代码差点让我社死
前端
anOnion4 小时前
构建无障碍组件之Checkbox pattern
前端·html·交互设计
IT枫斗者6 小时前
IntelliJ IDEA 2025.3史诗级更新:统一发行版+Spring Boot 4支持,这更新太香了!
java·开发语言·前端·javascript·spring boot·后端·intellij-idea
N***p3656 小时前
Spring Boot项目接收前端参数的11种方式
前端·spring boot·后端
享誉霸王7 小时前
15、告别混乱!Vue3复杂项目的规范搭建与基础库封装实战
前端·javascript·vue.js·前端框架·json·firefox·html5
a1117767 小时前
飞机躲避炸弹 网页游戏
前端·开源·html·threejs
夏乌_Wx7 小时前
mybash:简易 Shell 实现的设计思路与核心模块解析
linux·服务器·前端