已掉线,重新登录

首页 > 绿虎论坛 > 历史版块 > 编程 > PHP > 讨论/求助

标题: 高手来看看php.

作者: @Ta

时间: 2012-08-14

点击: 1787

<?php
error_reporting(0);
$time=$_GET['time'];
$num=$_GET['num'];
$siteid=$_GET['siteid'];
$classid=$_GET['classid'];
$domain=$_GET['domain'];
$sid=$_GET['sid'];if(!$siteid or !$classid or !$domain or !$sid or!$time or $num>100){
echo"<font color='red'>输入不完整<a href='index.php?q=2'>返回重新填写</a></font>";
}else{
?>
<html>
<head>
<title>页面</title>
<META HTTP-EQUIV="Refresh" content="3">
</head>
<body>
<?php
ignore_user_abort(true);
set_time_limit(0); //设置程序执行时间无限制 
$txt=file('reply.txt');
for($j=1;$j<$num;$j++) {
shuffle($txt);
#要提交的数据串
$postdata="action=gomod&book_title=$txt[2]&siteid=$siteid&lpage=1&book_content=$txt[3]&classid=$classid&sid=$sid";
#要提交到的网址
$url=$domain."/bbs/book_view_add.aspx";
$optionpost=array('http'=>array('method'=>"POST",'timeout'=>"60",'header'=>"User-Agent:Mozilla/4.0(compatible;MSIE 7.0;Windows NT 6.0;SLCC1;.NET CLR 2.0.50727;Media Center PC 5.0;.NET CLR 3.5.21022;.NET CLR 3.0.04506;CIBA)\r\nAccept:*/*",'content'=>$postdata));
$file=file_get_contents($url,false,stream_context_create($optionpost));
echo$file;
sleep($time);
}
?>
</body>
</html>
<?php
}
?>呵呵,我想大家都知道干嘛用的!
我想问那个获取.txt的时候,如果我想从获取2个不同的.txt中获取,该怎么修改?

[隐藏样式|查看源码]


『回复列表(3|隐藏机器人聊天)』

1. include 'a.txt';
include 'b.txt';
(/@Ta/2012-08-14 23:55//)

2.
用户被禁言,发言自动屏蔽。
(/@Ta/2012-08-14 23:58//
被禁言
)

3. @浪人  谢谢!  @Cute   发贴子用的!
(/@Ta/2012-08-15 00:10//)

回复需要登录

8月11日 01:19 星期一

本站由hu60wap6驱动

备案号: 京ICP备18041936号-1