1
hervet
Guide, how to solve problems caused by Wordbook
  • 2008/10/15 8:24

  • hervet

  • Friend of XOOPS

  • Posts: 2267

  • Since: 2003/11/4


Hello,

Wordbook's blocks can cause many troubles to the other modules.

Here is a fix.
Edit /xoops/modules/wordbook/blocks/entries_top.php
and replace line 13 :
global $xoopsDB$xoopsModule$xoopsUser;


with :
global $xoopsDB;


edit /xoops/modules/worbook/blocks/entries_new.php
replace line 12 :
global $xoopsDB$xoopsModule$xoopsModuleConfig$xoopsUser;


with :
global $xoopsDB$xoopsUser;


and finally, in /xoops/modules/wordbook/blocks/random_term.php replace line 13 :
global $xoopsDB$xoopsConfig$xoopsModule$xoopsModuleConfig$xoopsUser;


with :
global $xoopsDB$xoopsConfig$xoopsUser;


A side effect of the bugs of its blocks is that other modules "loose" their preferences (and many things else like comments).

Bye,
Hervé

2
Anonymous
Re: Guide, how to solve problems caused by Wordbook
  • 2008/10/15 9:33

  • Anonymous

  • Posts: 0

  • Since:


Excellent - thank you

3
McDonald
Re: Guide, how to solve problems caused by Wordbook
  • 2008/10/15 9:44

  • McDonald

  • Home away from home

  • Posts: 1072

  • Since: 2005/8/15


Wordbook 1.16 has some overkill when it comes to the use of 'global'.

Ofter $xoopsUser is listed twice as you can see in entry.php:
global $xoopsUser$xoopsUser$xoopsConfig$xoopsDB$modify$xoopsModuleConfig$xoopsModule$XOOPS_URL;


Also, this typo has been found a few times:
list($numrows) = $xoopsDB -> fetchRow($xoopsDB->query("SELECT COUNT(*) FROM ".$xoopsDB -> prefix("wbentries")." WHERE submit = 'O' AND offline = '0'"));

This is line 155 from index.php.
Instead of submit = 'O' (Ooooh) it should be submit = '0' (zero).

I think that Encyclopedia, which is based on Wordbook 1.17 beta, has similar problems.

Login

Who's Online

209 user(s) are online (138 user(s) are browsing Support Forums)


Members: 0


Guests: 209


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Apr 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits