I install and configure banner module but still get this error:

Illegal offset type in /DISK2/WWW/hipo.cz/www/drupal/banner_db.php on line 19.

Can anybody help me plesae

Comments

mikesharp’s picture

and no banner shows though the count increases in the admin section?

PaulM’s picture

but I still not fix this problem :-(

Dan McDermott’s picture

did u ever figure this one out?

smokey-1’s picture

this seems to have fixed my problem. banner_db.php is confused about the $ballot and $banners structure. adding another level (the $tid) seems to have fixed it.

here's what i did:

in banners_db.php... after the following line:

ADD THIS LINE...

  $tid = (int)$_GET["tid"];

...after this line (line 5)...

  $pos = (int)$_GET["pos"];

then, REPLACE THESE LINES (lines 18 and 19)...

  $id = $ballot[$pos][$random];
  $banner = $banners[$id];

...with these lines...

  $id = $ballot[$tid][$pos][$random];
  $banner = $banners[$tid][$id];

i'm using drupal 4.6.3, banner 4.6.0

before the fix, the banners wouldn't display... it seems to be working now.

Dan McDermott’s picture

That did the trick. Now I see them for the first time. Thanks so much!

Now it won't hold the owner information. Any idea why?

Dan McDermott’s picture

Okay I was putting the username when it was asking for the user id. reminds me of an old saying my uncle used to tell me: computers will do exactly what you tell them to do--not what you THOUGHT you told them to do... lol

Dan McDermott’s picture

Do you find that the banner module--once working--has been stable and accurate and useful for advertisers in the long term? we are getting ready to start selling ads to recover our costs and i am scared that there will be some major problem and paying advertisers won't be amused...

Dan McDermott’s picture

The stats seem to work now but I have four test banners all in group 1 with exactly the same settings. It was only showing the first in the list over and over again. Then i disabled the first to see what would happen. Now it only shows the second one over and over.

Again, I have checked and rechecked all the settings and they are identical.

Dan McDermott’s picture

I had banner caching off. apparently with cache off only one banner displays. with it on it appears to work correctly.
sorry to make you read all this only for me to solve it a few hours later.
i think i should start my own forum and just ask myself questions and then diagnose them and write myself back, lol.