Forums / Developer / Please help: pagelayout for modules

Please help: pagelayout for modules

Author Message

Claire Lin

Thursday 24 July 2003 3:05:29 pm

I've asked this quesiton twice, and have tried answer my own qestion by looking at the code on template in the mean time -- without success. Please help.

The quesiton is: How do I make sure that advancedsearch.tpl shows under a certain pagelayout? (Similarly, how do I make sure that the basket.tpl shows under a certain pagelayout?) Because Search and Shop are not part of the Content module, I do not know how to assign "section" (and in turn pagelayout) to them.

Anyone please give me some clue? Even just where to look for the relevant php codes will be great...

Thanks a lot in advance.
Claire

Alex Jones

Friday 25 July 2003 6:35:31 am

Out of curiousity, have you tried to turn on template debugging so it displays each template that is used on the page? This might give you an idea of where the code for search and shopping are generated.

Change the following code (disabled > enabled) in site.ini or add it to the site.ini.append for the site you are working on to enable debugging.

[TemplateSettings]
Debug=disabled

Just a thought,

Alex

Alex
[ bald_technologist on the IRC channel (irc.freenode.net): #eZpublish ]

<i>When in doubt, clear the cache.</i>

Jan Borsodi

Saturday 26 July 2003 4:31:51 am

You should take a look at the kernel/user/login.php file, look at the bottom and you'll see the lines.

if ( $ini->variable( 'SiteSettings', 'LoginPage' ) == 'custom' )
$Result['pagelayout'] = 'loginpagelayout.tpl';

Which tells eZ publish to use loginpagelayout.tpl for pagelayout template instead of the standard.
The 'if' statement is only there to see if a custom layout should be used.

The downside to this method is that you have modify the code for advanced search. We generally do not recommend this due to problems with future updates.

--
Amos

Documentation: http://ez.no/ez_publish/documentation
FAQ: http://ez.no/ez_publish/documentation/faq

Jan Borsodi

Saturday 26 July 2003 5:30:09 am

I started a discussion on how this can be solved without PHP code here:
http://ez.no/developer/ez_publish_3/forum/suggestions/applying_features_to_modules_and_views

--
Amos

Documentation: http://ez.no/ez_publish/documentation
FAQ: http://ez.no/ez_publish/documentation/faq

Claire Lin

Sunday 27 July 2003 10:25:33 am

Thank you~!! I've changed the relevant php code.
Claire

eZ debug

Timing: Jan 18 2025 15:02:56
Script start
Timing: Jan 18 2025 15:02:56
Module start 'content'
Timing: Jan 18 2025 15:02:58
Module end 'content'
Timing: Jan 18 2025 15:02:58
Script end

Main resources:

Total runtime1.4426 sec
Peak memory usage4,096.0000 KB
Database Queries202

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0058 588.8516180.8281
Module start 'content' 0.00581.2286 769.6797603.9453
Module end 'content' 1.23440.2081 1,373.6250337.3672
Script end 1.4425  1,710.9922 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00390.2699210.0002
Check MTime0.00130.0924210.0001
Mysql Total
Database connection0.00070.051610.0007
Mysqli_queries1.359794.25422020.0067
Looping result0.00220.15562000.0000
Template Total1.407497.620.7037
Template load0.00190.134120.0010
Template processing1.405497.422120.7027
Template load and register function0.00020.010810.0002
states
state_id_array0.00140.098110.0014
state_identifier_array0.00260.181820.0013
Override
Cache load0.00160.1091320.0000
Sytem overhead
Fetch class attribute can translate value0.00220.151040.0005
Fetch class attribute name0.00090.065170.0001
XML
Image XML parsing0.00140.095740.0003
class_abstraction
Instantiating content class attribute0.00000.001080.0000
General
dbfile0.00310.2181340.0001
String conversion0.00000.000430.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
5content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
9content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
6content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
3content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 25
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs