Forums / General / Deprecated template language elements

Deprecated template language elements

Author Message

Piotrek Karaś

Sunday 15 April 2007 12:27:05 am

Hello,

I stood my first eZ publish steps already in 3.8's and in its documentation I found a number of template language elements marked 'deprecated'. Now 3.9's are already out there with a solid amount of such elements still being used. The major one is <b>section</b> control structure. So I started to wonder if it was actually a good idea to have avoided all the deprecated items in my templates? How come 3.9 still uses <b>section</b>? Is it just the matter of time and energy consuming transcription, or are there any other reasons? Is there any instruction on how to understand 'deprecated' in the eZ publish context?

Just wondering...

--
Company: mediaSELF Sp. z o.o., http://www.mediaself.pl
eZ references: http://ez.no/partners/worldwide_partners/mediaself
eZ certified developer: http://ez.no/certification/verify/272585
eZ blog: http://ez.ryba.eu

kracker (the)

Sunday 15 April 2007 1:15:07 am

<i>Do as we say not as we do ... </i> ?:P or <i>Pay no attention to the man behind the curtain!</i> ;D

Seriously though for a moment. The stock design templates still do contain deprecated template operators. I'd imagine these are kept in place until the next big thing hits the scene, 'eZ Publish 4'. Which at the least might have an opportunity to consider maintaining backwards compatibility or moving forward. I'd imagine we will see eZ moving forward...

Deprecated often refers to features which are no longer recommended for use yet may still be included in an effort to provide compatibility for users of older versions of eZ Publish. While it is best not to rely on deprecated functionality, eZ provides the users with a lot of freedom to slowly adapt their own compatibility with the latest supported features as it makes sense to the end user. Compatibility like content can be King.

Stay tuned ...

//kracker

<i>Sole : mansbestfriend : Judges Ain't Nothing But Guts With A Halo</i>

Member since: 2001.07.13 || http://ezpedia.se7enx.com/

Piotrek Karaś

Sunday 15 April 2007 12:48:29 pm

Yes, I agree, backward compatibility is very appreciated and I have nothing against it as well as I understand why new standards aren't incorporated at once. It just feels weird when you modify (recode) most of the out-of-the-box templates :)
Greetings!

--
Company: mediaSELF Sp. z o.o., http://www.mediaself.pl
eZ references: http://ez.no/partners/worldwide_partners/mediaself
eZ certified developer: http://ez.no/certification/verify/272585
eZ blog: http://ez.ryba.eu

André R.

Monday 16 April 2007 1:35:54 am

For the 3.x series the rule has been to use the new syntax on new templates, like in ezwebin / Website interface.
Even if the template component syntax is closer to the 'new syntax' then the 'old', its still differences:
http://ez.no/doc/components/view/trunk/(file)/Template_syntax.html#template-language

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

Piotrek Karaś

Monday 16 April 2007 1:35:06 pm

@André R.: The components syntax looks promising at first glance. Can you just please explain how are eZ publish and eZ components exactly related (maybe a link)? I'm considerably new to eZ world and I haven't figured it out yet. Will future versions eZ publish port to eZ components? Sorry for silly questions :)

--
Company: mediaSELF Sp. z o.o., http://www.mediaself.pl
eZ references: http://ez.no/partners/worldwide_partners/mediaself
eZ certified developer: http://ez.no/certification/verify/272585
eZ blog: http://ez.ryba.eu

André R.

Monday 16 April 2007 3:39:48 pm

Re: eZ Publish and eZ Components
eZ Publish 4.0 will be php 5 ( probably 5.1.1 and up like eZ Components ) based and use eZ Components:
http://ez.no/community/news/community_newsletter_2_9th_february_2007

Note however that not all the components will be used for eZ Publish 4.0, some will have to wait for later versions either because of time constraints or missing features in the component them self.

Using components have clear advantages, the have a clear api, well documented and are unit tested as individual components(building blocks). On top of that they are written purely for php5+.

Expect more on this during the summer conference :)

So to sum this thread up, there are no plan to this day to remove deprecated template elements in 3.x lifespan, but writing code in new syntax will give you two adwantages:
1. It's easier to read and maintain
2. It's give you an edge when you some time next year start migrating existing code to eZ Publish 4.0

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

Piotrek Karaś

Monday 16 April 2007 3:56:07 pm

No further doubts ;) Thanks!

--
Company: mediaSELF Sp. z o.o., http://www.mediaself.pl
eZ references: http://ez.no/partners/worldwide_partners/mediaself
eZ certified developer: http://ez.no/certification/verify/272585
eZ blog: http://ez.ryba.eu

eZ debug

Timing: Jan 18 2025 19:18:42
Script start
Timing: Jan 18 2025 19:18:42
Module start 'content'
Timing: Jan 18 2025 19:18:43
Module end 'content'
Timing: Jan 18 2025 19:18:43
Script end

Main resources:

Total runtime1.3332 sec
Peak memory usage4,096.0000 KB
Database Queries208

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0084 588.8438180.8359
Module start 'content' 0.00841.1747 769.6797650.6328
Module end 'content' 1.18310.1501 1,420.3125345.0625
Script end 1.3332  1,765.3750 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00490.3687210.0002
Check MTime0.00210.1562210.0001
Mysql Total
Database connection0.00160.118110.0016
Mysqli_queries1.233292.49442080.0059
Looping result0.00260.19472060.0000
Template Total1.301597.620.6508
Template load0.00200.153520.0010
Template processing1.299597.468020.6497
Template load and register function0.00010.006810.0001
states
state_id_array0.00080.056910.0008
state_identifier_array0.00100.073120.0005
Override
Cache load0.00180.1370410.0000
Sytem overhead
Fetch class attribute can translate value0.00170.124140.0004
Fetch class attribute name0.00180.1376100.0002
XML
Image XML parsing0.00180.136740.0005
class_abstraction
Instantiating content class attribute0.00000.0021140.0000
General
dbfile0.00240.1793430.0001
String conversion0.00000.000630.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

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
7content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
7content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
8content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
4content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 28
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs