最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
php file_get_contents读取远程文件并输出
时间:2008-07-26 编辑:简简单单 来源:一聚教程网
php file_get_contents读取远程文件并输出,这样做的好得就是不会在flash播放代码中显示对方网站的文件地址,下面是我自己用的一个.是读取方视频文件用的.
require_once("s/s.php");
$a_id =get_value('id','');
if(is_numeric($a_id) ){
$result =mysql_query("Select * from s where id='$a_id'") or die(mysql_error());
if( mysql_num_rows($result) ){
$rs =mysql_fetch_array( $result );
$swfpath=$rs[5];
}
}
function Get_swf($url){
$data = file_get_contents($url);
header("content-type: application/x-shockwave-flash");
echo $data;
}
?>
本站原创: www.111com.net 转载请注明来处.
-
上一个: 新浪编辑器的调用
相关文章
- php file_get_contents()读取采集远程文件内容 07-21
- PHP导出数据超时的优化建议解读 10-31
- PHP之mysql位运算解析 10-31
- Laravel实现登录跳转功能解析 10-31
- php双向队列解读 10-31
- Laravel异常上下文解决教程 10-24