Errors with Debug output from out of the box solution

Author Message

John Smith

Wednesday 05 March 2008 7:56:40 am

Hi there,

I installed ezpublish 4.0 with simple plain site style. Created a new class "Article Events" and linked to the calender in the Toolbar management -> right

Got the following debug output.

Non-static method eZContentObjectTreeNode::calendar() should not be called statically, assuming $this from incompatible context in

\kernel\content\ezcontentfunctioncollection.php on line 317

Strict: PHP

Non-static method eZContentObjectTreeNode::subTreeGroupByDateField() should not be called statically in

\kernel\classes\ezcontentobjecttreenode.php on line 1426

André R.

Wednesday 05 March 2008 12:56:12 pm

Non-static method eZContentObjectTreeNode::calendar() should not be called statically, assuming $this from incompatible context in

This is fixed in 4.0.1 (upcoming version):
http://issues.ez.no/IssueView.php?Id=12074&activeItem=1

As for:

Non-static method eZContentObjectTreeNode::subTreeGroupByDateField() should not be called statically in

\kernel\classes\ezcontentobjecttreenode.php on line 1426

I have created a issue for it here:
http://issues.ez.no/IssueView.php?Id=12654

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

John Smith

Thursday 06 March 2008 4:54:12 am

Is it possible to see the changes for the issue 12074 please which has been fixed?

Another entry in logs:

mktime() [<a href='function.mktime'>function.mktime</a>]: You should be using the time() function instead in var\plain_site\cache\template\compiled\folder_full_events-0411fccf18ca4a33d0b99d11e31d8e68.php on line 288.

I checked the complied folder and the line 288 is:

$var = mktime(  );

Hope you can help me on this one as well.

André R.

Thursday 06 March 2008 5:11:55 am

> Is it possible to see the changes for the issue 12074?

yes you can check out a specific svn revision (21240) and compare it to the previous revision.
Or you can use the viewCVS interface:
http://pubsvn.ez.no/viewcvs/stable/4.0/kernel/classes/ezcontentobjecttreenode.php?rev=21433&root=nextgen&sortby=date&view=log

about the mktime issue, you should report this in the issue tracker.
But you need to write a bit more information, like what template this comes from and if possible what template operator ( / function ) generates this code. (you can find the template used in the top of that compiled template ).

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

John Smith

Thursday 06 March 2008 6:02:52 am

Cheers,

I will look at the template first, if critical then report it as a issue.

Another thing, would it be possible for you to send me a link where I can see all the changes or bug fixes from 4.0.0 to 4.0.1.

When is the version 4.0.1 releasing please???

John Smith

Thursday 06 March 2008 6:42:39 am

Acutally in the template the code was:

timestamp=maketime()
current=gettime($timestamp)

I changed to :

current=gettime($currentdate())

It is working fine now. No errors in the logs file except:

Non-static method eZContentObjectTreeNode::subTreeGroupByDateField() should not be called statically in \kernel\classes\ezcontentobjecttreenode.php on line 1426

André R.

Thursday 06 March 2008 9:47:28 am

If you want to remove the notice badly, you can safely add a 'static' in front of that function, it does not use '$this' so can be declared static.

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Kristof Coomans

Thursday 06 March 2008 10:59:50 am

I reported the strict warning with maketime here: http://issues.ez.no/12664

independent eZ Publish developer and service provider | http://blog.coomanskristof.be | http://ezpedia.org

John Smith

Friday 07 March 2008 10:22:39 am

Cheers, André R for the quick fix.

Is there any quick fix for:

Non-static method eZContentObjectTreeNode::subTreeGroupByDateField() should not be called statically in

\kernel\classes\ezcontentobjecttreenode.php on line 1426

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 19 2025 15:25:19
Script start
Timing: Jan 19 2025 15:25:19
Module start 'layout'
Timing: Jan 19 2025 15:25:19
Module start 'content'
Timing: Jan 19 2025 15:25:20
Module end 'content'
Timing: Jan 19 2025 15:25:20
Script end

Main resources:

Total runtime0.8550 sec
Peak memory usage4,096.0000 KB
Database Queries77

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0052 589.3984152.6563
Module start 'layout' 0.00520.0029 742.054739.5078
Module start 'content' 0.00800.8459 781.5625656.5156
Module end 'content' 0.85400.0010 1,438.078120.1094
Script end 0.8550  1,458.1875 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00330.3901160.0002
Check MTime0.00130.1557160.0001
Mysql Total
Database connection0.00100.114910.0010
Mysqli_queries0.790792.4717770.0103
Looping result0.00060.0732750.0000
Template Total0.825396.520.4126
Template load0.00220.259520.0011
Template processing0.823096.258420.4115
Template load and register function0.00010.017210.0001
states
state_id_array0.00080.093110.0008
state_identifier_array0.00070.083020.0004
Override
Cache load0.00200.2309580.0000
Sytem overhead
Fetch class attribute can translate value0.00050.057230.0002
Fetch class attribute name0.00080.0938110.0001
XML
Image XML parsing0.00110.127830.0004
class_abstraction
Instantiating content class attribute0.00000.0024130.0000
General
dbfile0.00090.1087230.0000
String conversion0.00000.000840.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
9content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
15content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
4content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
5content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
4content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 39
 Number of unique templates used: 7

Time used to render debug report: 0.0001 secs