Sorry, this was a bad question that I revised to make it less localized. I’ve learned to narrow down my questions to the actual cause. If anyone could up-vote the question so I can once again ask questions on stack I would be VERY grateful.
I keep getting an error from this line.
$file = $files[ rand( 0, count( $files ) ) ];
It throws the timezone undefined, unset array or function already defined.
Notice: Undefined offset: 5 in
/home/public_html/adserve.php on line 15
adserve.php
Shared hosting so no access to the php.ini file.
There are not random errors. The first one pretty much tells you what you need to do to fix it.
In the second one, if line 15 of your code is this:
Then your undefined offset problem lies in the fact that the highest index value in a zero-indexed array like you are using will be
count - 1.Thus your line should be