On 4 Oct 2000, at 21:30, ___cliff rayman___ wrote:
> i'll take a late night stab at it.
> which random function are u using and where is it getting its randomness? i know
>some of them will just block if there is nothiing to produce entropy. perhaps apache
>is timing out and that is where the broken pages are coming from.
Simple rand() function.
Index.html calls via [- Execute() -] a separate file which performs
one random call and on database update.
Btw. do multiple 'execute' functions get called in parallel when done
in one embperl file? eg. when I have 5 files included in index.html
via Execute could they start accessing db at the same time?
If so - is there an option to have a simple 'include' so the embperl
parser runs the final code as if it was contained in one file?
Or is the only way to move all the included files into one?
TIA,
Henri Laupmaa
Inspiral Network
+372 55 24542
------------------- The main function in the included file
[-
srand();
$random = int(rand($maxnr));
$banner = &CONCOM::sql("SELECT * from banner where
tyyp=$tyypid limit $random,1;");
$id = $$banner[0][0];
$link = $$banner[0][2];
$img = $$banner[0][3];
$view = ($$banner[0][6])+1;
&CONCOM::sql("UPDATE banner set view=$view where
banner_id=$id;");
-]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]