Error display and solving them

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Locked
User avatar
AccentAvondschool
Forum Members
Forum Members
Posts: 28
Joined: Sun May 08, 2016 5:36 am
Location: Rotterdam NL

Error display and solving them

Post by AccentAvondschool »

Hi,

I almost successfully converted the website of our school from CMSMS v1.12.2 to v2.2.10 on subdomain (www1).
After quite a few smarty adjustments everything (menu/calendar/news/etc) seems to work (on screen) but the error logs still show some PHP warnings but I have no idea where to look. Some lines of code ...

Code: Select all

[Mon May 20 11:14:14.608096 2019] [fcgid:warn] [pid 14027:tid 139848157689600] [client 84.84.7.27:57657] mod_fcgid: stderr: PHP Warning:  A non-numeric value encountered in /var/www/vhosts/accentavondschool.nl/domains/www1.accentavondschool.nl/tmp/templates_c/1f872bb2407ba11fb3b08117a364153d774ad774_0.tpl_top.58.php on line 34, referer: https://www1.accentavondschool.nl/
[Mon May 20 11:14:14.608223 2019] [fcgid:warn] [pid 14027:tid 139848157689600] [client 84.84.7.27:57657] mod_fcgid: stderr: PHP Warning:  Parameter 2 to smarty_postfilter_noopener() expected to be a reference, value given in /var/www/vhosts/accentavondschool.nl/domains/www1.accentavondschool.nl/lib/smarty/sysplugins/smarty_internal_runtime_filterhandler.php on line 57, referer: https://www1.accentavondschool.nl/
Is there a way to get the error messages a little easier to understand, for example which block or code generates the error?

Thanks in advance
Accent Avondschool - https://www.accentavondschool.nl/
René
Regards,

Accent Avondonderwijs
René
User avatar
DIGI3
Dev Team Member
Dev Team Member
Posts: 1032
Joined: Wed Feb 25, 2009 4:25 am
Location: Victoria, BC

Re: Error display and solving them

Post by DIGI3 »

These are warnings so won't bring your site down. Usually they're just modules which need minor updates for your version of PHP.

PHP is reporting those errors, they're not generated by CMSMS. But you can probably find out what is causing them by looking at the files it lists, and the line number specified. These particular ones are in cache files so you'll have to look at them before clearing the cache.
Not getting the answer you need? CMSMS support options
User avatar
velden
Dev Team Member
Dev Team Member
Posts: 3272
Joined: Mon Nov 28, 2011 9:29 am
Location: The Netherlands

Re: Error display and solving them

Post by velden »

First warning:
.._0.tpl_top.58.php ...

Suggests it's something at the very top (before <__html>) of your page template. I'm not sure if it can be included templates (global content blocks or others too).

Second warning:

https://cmscanbesimple.org/blog/solutio ... nerability
User avatar
AccentAvondschool
Forum Members
Forum Members
Posts: 28
Joined: Sun May 08, 2016 5:36 am
Location: Rotterdam NL

Re: Error display and solving them

Post by AccentAvondschool »

@DIGI3 & @velden thank you for your quick responses.

Domain www1.accentavondschool.nl runs on latest PHP 7.2.18 and because the log file is already 50Mb I want to reduce these warning messages.

I am going to view your advice and links, thanks for this information.

Regards,
René
Regards,

Accent Avondonderwijs
René
User avatar
DIGI3
Dev Team Member
Dev Team Member
Posts: 1032
Joined: Wed Feb 25, 2009 4:25 am
Location: Victoria, BC

Re: Error display and solving them

Post by DIGI3 »

It's good to sort them out, but you can always change the reporting level to not include warnings. Typically you just enable the warnings on development sites, not production.
Not getting the answer you need? CMSMS support options
calguy1000
Support Guru
Support Guru
Posts: 8169
Joined: Tue Oct 19, 2004 6:44 pm
Location: Fernie British Columbia, Canada

Re: Error display and solving them

Post by calguy1000 »

Code: Select all

smarty_postfilter_noopener()
This is not a core function. But you may have added a postfilter function.
You can look in your assets/plugins or lib/plugins directory for a file containing that filter.

Or look in your UDT's
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
User avatar
Rolf
Dev Team Member
Dev Team Member
Posts: 7739
Joined: Wed Apr 23, 2008 7:53 am
Location: The Netherlands

Re: Error display and solving them

Post by Rolf »

The second warning is already fixed in the blog:
https://cmscanbesimple.org/blog/solutio ... nerability
Update your plugin file with the latest code.
Image
- + - + - + - + - + -
Latest CMSMS tutorial: FormBuilder WatchGuard
- + - + - + - + - + -
Did my post help you solving a problem at your (customers) website and it saved you many hours of work?
Great!! Buy me a cup of coffee in return as a small token of appreciation!
User avatar
AccentAvondschool
Forum Members
Forum Members
Posts: 28
Joined: Sun May 08, 2016 5:36 am
Location: Rotterdam NL

Re: Error display and solving them

Post by AccentAvondschool »

@Rolf, calguy1000,

Thx for your responses.

I've indeed added the postfilter function 'postfilter.noopener.php' and it is already active on the current site (http://www.accentavondschool.nl).
On the new site (www1.accentavondschool.nl) this file is in the new plugin folder. I just compared them and the only difference with my code and the code from https://cmscanbesimple.org/blog/solutio...nerability was the Ampersand for $smarty in my code like ...

Code: Select all

function smarty_postfilter_noopener($tpl_output, &$smarty) {
Also is the latest blog version 1.15.8 active on the new site (www1.accentavondschool.nl)

Regards,
René
Regards,

Accent Avondonderwijs
René
Locked

Return to “Modules/Add-Ons”