Cn.modao 发表于 2006 年 8 月 1 日 14:20:28

谁还有以前那个刷新一次改变一次图片的php代码

同上!
拿来有用1

坏蛋安迪 发表于 2006 年 8 月 1 日 15:05:15

俺没有

ashun 发表于 2006 年 8 月 1 日 15:05:48

我头像

星辰 发表于 2006 年 8 月 1 日 15:05:58

忘记了~

ashun 发表于 2006 年 8 月 1 日 15:06:36

http://blog.zzxt.com/?action=show&id=17

Cn.modao 发表于 2006 年 8 月 1 日 15:07:15

原帖由 ashun 于 2006-8-1 15:06 发表
<?php
$url='tx';
$files=array();
if ($handle=opendir("$url")) {
while(false !== ($file = readdir($handle))) {
    if ($file != "." && $file != ".." ...


晕..
用代码的方式贴出来啊~~
我这个样子复制下去全部是...

ashun 发表于 2006 年 8 月 1 日 15:07:53

原帖由 永远の魔道 于 2006-8-1 15:07 发表



晕..
用代码的方式贴出来啊~~
我这个样子复制下去全部是...
http://blog.zzxt.com/?action=show&id=17
我blog

Cn.modao 发表于 2006 年 8 月 1 日 15:08:28

3Q

oghuz 发表于 2006 年 8 月 1 日 15:13:40


<?php
$url='img'; //图片地址,只可以用./you/images这样的路径
$files=array();
if ($handle=opendir("$url")) {
;;; while(false !== ($file = readdir($handle))) {
;;;;;;;;; if ($file != "." && $file != "..") {
;;;;;;;;; if(substr($file,-3)=='gif' || substr($file,-3)=='jpg') $files = $file;
;;;;;;;;; }
;;; }
}
closedir($handle);
$random=rand(0,count($files)-1);
if(substr($files[$random],-3)=='gif') header("Content-type: image/gif");
elseif(substr($files[$random],-3)=='jpg') header("Content-type: image/jpeg");
readfile("$url/$files[$random]");
?>

ppopcn 发表于 2006 年 8 月 1 日 16:51:30

我原来写了一个随机图片的JS代码!
页: [1] 2
查看完整版本: 谁还有以前那个刷新一次改变一次图片的php代码