随机视频,天气查询

This commit is contained in:
muzihuaner
2026-03-18 13:16:49 +08:00
parent cf64fdc6f5
commit a5a679b69b
4 changed files with 298 additions and 0 deletions

View File

@@ -1,3 +1,13 @@
<?php
$file = 'counter.dat';
// 读取并自增
$counter = (int)@file_get_contents($file);
$counter++;
// 使用 LOCK_EX 防止并发写入冲突
file_put_contents($file, $counter, LOCK_EX);
?>
<?php
Header('content-type: application/json');
require ('../../curl.php');//引进封装好的curl文件