Forums / Setup & design / custom classes and edition in user siteaccess

custom classes and edition in user siteaccess

Author Message

Guillaume Clapier

Friday 12 January 2007 7:13:39 am

Hello

I am having a REALLY hard time with the custom classes that I create. I successfully use the override function to print my class in my user siteaccess using /design/{siteaccess}override/templates then |full|line etc...

I have noticed there is and edit folder in there as well, which i intended to use. I also have modfied the override.ini.append.php file for all the views that i need, including edit.
BUT (there's always a but somewhere) the toolbar that says edit|remove etc.. never shows up in the full view for the objects I have created myself, and its driving me crazy!

At first I thought it was a problem of right, but it is defenitly NOT that (it does that even with an admin user that has rights set to all modules allfunctions no limits).

Any ideas, links, whatever is useful that could help me out there?

Thank you,
G

Eirik Alfstad Johansen

Tuesday 16 January 2007 9:22:35 am

Hi Guillaume,

I'm guessing that when you have created your overrides, you have based them upon copies of the default templates which, among other things, include buttons for editing/removing the object (at least the default node/view/full.tpl).

If you take a closer look at your overrides, you should be able to find the buttons near the bottom of the code.

A little tip: When I create overrides, I usually do it through the admin interface, basing the override on either "Container (with children)" or "View (without children)" depending on whether I'm overriding full.tpl or line.tpl. I find that this gives me a much better starting point than copying the default template.

Sincerely,

Eirik Alfstad Johansen
http://www.netmaking.no/

Guillaume Clapier

Wednesday 17 January 2007 9:13:12 am

Well thank you for your answer Eirik,

actually I have been on the problem for a while and I think I understand what is going on better now. I do not think it is a problem with the templates I used (I do not edit them through the web interface but via ssh directly on my server, copying the template I find closer to what I will be doing and modifying it), because I found that the file that displays the toolbar is websitetoolbar.tpl .
I managed (with some help) to locate the problem which lies in the $available_for_classes variable rather. It seems one needs to create a file 'websitetoolbar.ini' and you have to add your classes up in there. When the program goes through the websitetoolbar.tpl the $available_for_classes will contain you class and thus the condition will be true, and the program will enter the condition, displaying the toolbar. For the moment I have not found the correct syntax for the ini file, I simply put the $available_for_classes variable to true, up until I find a way to write the file down correctly (I am still very new to EZ), and it works fine, underlying the fact that this variable was the one causing the problem.
Now maybe when you make a new template through the website interface it automatically adds your class to the ini file, I don't know I'll have to check that out, but the problem is that I haven't found any documentation at all on this aspect of the program, so I am wondering how people do when they make new classes whose instances need to be edited by users really.
I am still working on EZ 3.9RC2, though.

Thank you,
Guillaume

eZ debug

Timing: Jan 18 2025 22:15:39
Script start
Timing: Jan 18 2025 22:15:39
Module start 'content'
Timing: Jan 18 2025 22:15:40
Module end 'content'
Timing: Jan 18 2025 22:15:40
Script end

Main resources:

Total runtime1.3090 sec
Peak memory usage4,096.0000 KB
Database Queries194

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0051 591.9297180.8125
Module start 'content' 0.00511.1950 772.7422547.6094
Module end 'content' 1.20010.1089 1,320.3516337.0547
Script end 1.3090  1,657.4063 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00390.2962210.0002
Check MTime0.00150.1114210.0001
Mysql Total
Database connection0.00050.036810.0005
Mysqli_queries1.242594.92231940.0064
Looping result0.00160.12421920.0000
Template Total1.282298.020.6411
Template load0.00230.173120.0011
Template processing1.279997.777620.6400
Template load and register function0.00030.019810.0003
states
state_id_array0.00090.068310.0009
state_identifier_array0.00110.087820.0006
Override
Cache load0.00190.1478250.0001
Sytem overhead
Fetch class attribute can translate value0.00120.091530.0004
Fetch class attribute name0.00100.076640.0003
XML
Image XML parsing0.00090.066130.0003
class_abstraction
Instantiating content class attribute0.00000.000740.0000
General
dbfile0.00470.3563270.0002
String conversion0.00000.000530.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
3content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
7content/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
1content/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: 17
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs