Quick question
| From: | Erik J. Barzeski | Date: | Mon, 04 Dec 2000 20:37:03 +0000 |
| Subject: | Quick question | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-28626@lists.php.net to get a copy of this message | ||
Hi,
I'm used to running PHP 4 and today I have a quick task (porting code)
to a machine that is unfortunately running PHP 3...
It doesn't like this function (and perhaps some others):
function is_super($someuser)
{
include("can_see_stats.inc");
for ($i = 0; $i < count($can_see_stats); $i++)
{
if ($can_see_stats[$i] == $someuser)
return true;
}
return false;
}
can_see_stats.inc contains:
<?php
$can_see_stats[] = "user1";
$can_see_stats[] = "user2";
$can_see_stats[] = "user3";
// etc.
?>
and this is used like:
if (is_super($username))
{
?><br><br><div align="center"><?
show_stats ();
?></div><?php
}
I get this error:
Fatal error: Call to unsupported or undefined function is_super() in
/home/erik/public_html/index.php3 on line 1
So... Am I doin' wrong? :)
--
Best wishes,
Erik J. Barzeski
Why do we ask rhetorical questions?
************************************************
Email: erik@barzeski.com
Web: http://www.barzeski.com/
http://www.soundsetcentral.com/
http://www.applescriptcentral.com/
AIM: iacas ICQ: 8186546
************************************************