Skip to content

Commit b7a3a7a

Browse files
committed
瀑布流demo
1 parent 99887dd commit b7a3a7a

50 files changed

Lines changed: 764 additions & 0 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

php/waterfall/data.php

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<?php
2+
// 接收 图片数量 与index.html 中boxParam: 'num',对应
3+
$num = $_GET["num"];
4+
// 接收最大页数参数 与index.html 中maxPage:0,对应
5+
$page = $_GET["page"];
6+
$data = array();
7+
// demo演示效果 预设最大页数为10页$page<11
8+
if($page < 11){
9+
for($i=0;$i<$num;$i++)
10+
{
11+
$pNum=rand(1,44);
12+
$data[$i]["img"] = "images/P".$pNum.".jpg";
13+
$data[$i]["title"] = "时间:".date("Y-m-d H:i:s")."<br />".($i+1)."、WindsWaterFlow(第".$page."页)";
14+
$data[$i]["href"] = "http://www.baidu.com";
15+
}
16+
}
17+
echo json_encode($data);
18+
19+
?>

php/waterfall/images/P1.jpg

24.4 KB

php/waterfall/images/P10.jpg

15.4 KB

php/waterfall/images/P11.jpg

18 KB

php/waterfall/images/P12.jpg

19.5 KB

php/waterfall/images/P13.jpg

17.2 KB

php/waterfall/images/P14.jpg

10.6 KB

php/waterfall/images/P15.jpg

14.1 KB

php/waterfall/images/P16.jpg

12.4 KB

php/waterfall/images/P17.jpg

11 KB

0 commit comments

Comments
 (0)