Opened 5 years ago

Closed 5 years ago

#843 closed Bug (fixed)

PHP 5.3 is throwing some notices

Reported by: halfdan Owned by:
Priority: normal Milestone: Piwik 0.4.2
Component: Core Keywords: php notices
Cc: Sensitive:

Description

I've just compiled PHP 5.3 and took a closer look at my log. I found the following notices/warnings:

[30-Jun-2009 23:13:59] PHP Warning: syntax error, unexpected $end, expecting TC_DOLLAR_CURLY or TC_QUOTED_STRING or '"' in /var/www/htdocs/piwik.c0demonkey.com/html/config/global.ini.php on line 145

in /var/www/htdocs/piwik.c0demonkey.com/html/core/Tracker/Config.php on line 62

[30-Jun-2009 23:13:59] PHP Notice: Undefined index: record_statistics in /var/www/htdocs/piwik.c0demonkey.com/html/core/Tracker.php on line 304
[30-Jun-2009 23:13:59] PHP Notice: Undefined index: download_url_var_name in /var/www/htdocs/piwik.c0demonkey.com/html/core/Tracker.php on line 265
[30-Jun-2009 23:13:59] PHP Notice: Undefined index: outlink_url_var_name in /var/www/htdocs/piwik.c0demonkey.com/html/core/Tracker.php on line 280
[30-Jun-2009 23:13:59] PHP Notice: Undefined index: download_url_var_name in /var/www/htdocs/piwik.c0demonkey.com/html/core/Tracker.php on line 265
[30-Jun-2009 23:13:59] PHP Notice: Undefined index: outlink_url_var_name in /var/www/htdocs/piwik.c0demonkey.com/html/core/Tracker.php on line 280

As they should be easy to fix I selected the Milestone Piwik 0.4.2

Attachments (1)

Config.diff (83 bytes) - added by halfdan 5 years ago.
diff patch

Download all attachments as: .zip

Change History (4)

comment:1 Changed 5 years ago by vipsoft (robocoder)

Can you please provide a patch?

comment:2 Changed 5 years ago by halfdan

Found out it's only a small adjustment in core/Tracker/Config.php.

Replace:

return $section

in get($name) with

return count($section) > 0 ? $section : null;

Changed 5 years ago by halfdan

diff patch

comment:3 Changed 5 years ago by vipsoft (robocoder)

  • Resolution set to fixed
  • Status changed from new to closed

(In [1265]) Fixes #843 - PHP 5.3 throwing some notices; patch from halfdan; thanks

Note: See TracTickets for help on using tickets.