求助,是否能帮忙看看什么错误。。。。

LnHanker 2005-10-25 07:11:13

Fatal error: Call to a member function Execute() on a non-object in D:\vod\index.php on line 21
...全文
61 4 打赏 收藏 转发到动态 举报
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
szjq 2005-10-26
  • 打赏
  • 举报
回复
你检查一下你的include文件是不是括进来了,调用不到原对像,没法继承
LnHanker 2005-10-25
  • 打赏
  • 举报
回复
怎么解决这个问题呢,你帮帮忙,你有QQ吗?或MSN
keke1688 2005-10-25
  • 打赏
  • 举报
回复
Call to a member function Execute() on a non-object in D:\vod\index.php on line 21
并不是一个可以执行的的函数对象!21行没有一个对象...
LnHanker 2005-10-25
  • 打赏
  • 举报
回复
<?php
function get_client_ip()
{
global $_SERVER;
if (isset($_SERVER["HTTP_X_FORWARDED_FOR"]))
{
$realip = $_SERVER["HTTP_X_FORWARDED_FOR"];
}
elseif (isset($_SERVER["HTTP_CLIENT_IP"]))
{
$realip = $_SERVER["HTTP_CLIENT_IP"];
}
else
{
$realip = $_SERVER["REMOTE_ADDR"];
}
return $realip;
}
require_once("conn.php");
$sql='update H_Sys set sys_count=sys_count+1';
$conn->Execute($sql);
$sql='select * from H_Sys';
$rs = $conn->Execute($sql);
$visiter_num= $rs->Fields['sys_count']->Value;
$sql='delete from H_Online where ('.time().'-online_time)>(20*60)';
$conn->Execute($sql);
$sql="insert into H_Online(online_ip,online_time) values('".get_client_ip()."',".time().")";
$conn->Execute($sql);
$sql='select count(*) as online_count from H_Online';
$rs = $conn->Execute($sql);
$online_count=$rs->Fields['online_count']->Value;
?>
<html>
<LINK href="images/font.css" type=text/css rel=stylesheet>
<BODY bgColor=#ffffff leftMargin=0 background=images/main_bg.gif topMargin=0>
<table cellSpacing=0 cellPadding=0 width=760 align=center bgColor=#de926b border=0><tr><td>
<?php require("top.php"); ?>
<?php require("newest.php"); ?>
</td></tr></table>
<TABLE height=25 cellSpacing=0 cellPadding=0 width=760 align=center border=0>
<TBODY>
<TR>
<TD bgColor=#003366 height=30>
</TD></TR></TBODY></TABLE>

</body>
</html>

21,891

社区成员

发帖
与我相关
我的任务
社区描述
从PHP安装配置,PHP入门,PHP基础到PHP应用
社区管理员
  • 基础编程社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧