Page 1 of 1
Statistics Module and Join PHP Warning
Posted: Thu Jan 23, 2014 6:15 pm
by JohnnyB
Is anyone else getting an error similar to
PHP Warning: join(): Invalid arguments passed in /public_html/modules/Statistics/Statistics.module.php on line 471
in their error logs?
CMSMS 1.11.9
Statistics 1.1.3
PHP 5.3.28
Maybe it is because of this bug report wrt building the keywords_array:
http://dev.cmsmadesimple.org/bug/view/9425
(I don't want to file a duplicate bug report....)
Re: Statistics Module and Join PHP Warning
Posted: Fri Jan 24, 2014 10:16 am
by paulbaker
Yes. Loads of them.
[23-Jan-2014 23:21:06 Europe/London] PHP Warning: join(): Invalid arguments passed in /home/stedward/public_html/modules/Statistics/Statistics.module.php on line 541
CMSMS 1.11.9 (happened with 1.11.7 too)
Statistics 1.1.3 *
PHP 5.4.21
* My Statistics module has this modification so that page name shows up:
http://dev.cmsmadesimple.org/bug/view/8512
Did you try the suggested resolution you linked to?
Re: Statistics Module and Join PHP Warning
Posted: Fri Jan 24, 2014 5:01 pm
by JohnnyB
I applied a similar fix I found here:
http://dev.cmsmadesimple.org/bug/view/9309
I think that worked... not sure yet.
Did you try the suggested resolution you linked to?
I did and still found join warnings today. But, I just realized that the join statement is reversed, right?
Shouldn't line 476 (479 now for mine):
Code: Select all
$statkeywords=$this->ReplaceKeywords(join($keyword_array, " "));
Be written as:
Code: Select all
$statkeywords=$this->ReplaceKeywords(join(" ", $keyword_array));
Re: Statistics Module and Join PHP Warning
Posted: Fri Jan 24, 2014 5:35 pm
by paulbaker
I agree, from
http://uk1.php.net/manual/en/function.implode.php I would say your second line is correct.
Re: Statistics Module and Join PHP Warning
Posted: Fri Jan 24, 2014 5:42 pm
by JohnnyB
Ahh, I'll file a bug report.
Re: Statistics Module and Join PHP Warning
Posted: Fri Jan 24, 2014 5:57 pm
by JohnnyB
I made the change and haven't received a new warning in the error log.