random-block standalone problem
zapzap
Joined: 2002-10-01
Posts: 3 |
Posted: Tue, 2002-10-01 02:05 |
i put the file in the gallery dir and and i see a picture ... good what is wrong ? thx |
|
zapzap
Joined: 2002-10-01
Posts: 3 |
Posted: Tue, 2002-10-01 02:05 |
i put the file in the gallery dir and and i see a picture ... good what is wrong ? thx |
|
Posts: 3
found the answer myself :smile:
chnage
the readCache() function
to this code
<!-- BBCode Start --><TABLE BORDER=0 ALIGN=CENTER WIDTH=85%><TR><TD><font class="pn-sub">Code:</font><HR></TD></TR><TR><TD><FONT class="pn-sub"><PRE>
function readCache()
{
global $cache;
if ($fd = fs_fopen(CACHE_FILE, "r"))
{
while ($line = fgets($fd, 4096))
{
list($key, $val) = explode("/", trim($line));
$cache[$key] = $val;
}
fclose($fd);
}
}</TD></TR></TABLE><!-- BBCode End -->
Posts: 172
I tried the code you provided, it solved but I keep getting errors:
Fatal error: Cannot redeclare readcache() (previously declared in /home/transit/public_html/photos/block-random.php:109) in /home/transit/public_html/photos/block-random.php on line 122
How I can fix it?