Shawn Sweet updates makes it very easy to add more ads and seperating them bravo!!!! but this is all i get on http://www.supportcave.com/ Y | o | u | | m on all my pages redid the file 2x and cleared out the .txt file any ideas!
Hmmm... looks like it might be trying to tell you "You must set your file to be writable". Strange it would split each character into an array though. Check that your .txt file is writable.
read this again so i have to change all my html code Because of this, the output of the $ad_network variable is no longer an array. For example, if you were outputting $ad_network[0] for a single ad before, you would need to change that to plain old $ad_network (that variable will contain everything you are outputting [including multiple ads]).
You could probably hack around on the ad_network.php file if you really want, to put it back into an array, but it really should be updated (you may also want to think about using an include so you only have to do it on one file).
I got that too. I had to move the .txt file to the http root and that fixed it. try moving the file .txt file to /httpdocs or /www and chmod 777
I had the same message about making my txt file writable, but it was already chmoded to 666. Anyways, I looked into Shawn's code and saw that the new txt file name was a little fdifferent from mine - it had "_212" at the end, so I changed the name and it worked. Thank you very much for the update Shawn! Very excited to see the charts
What about passthru.php? Just change $ad_network[0] to $ad_network? Is the following good? <?php if (!function_exists('file_get_contents')) { function file_get_contents($url) { $handle = fopen($url, 'r'); $string = fread($handle, 4096000); fclose($handle); return $string; } } include ('ad_network.php'); echo preg_replace ("/<\/body>/i", $ad_network . '</body>', file_get_contents(str_replace ('../', '', $_REQUEST['file']))); ?> Thanks