Forums / Developer / Module questions

Module questions

Author Message

Clemens T

Wednesday 11 May 2005 8:37:05 am

Hey all,
I'd like to ask your opinion on the following issue:

I'm having a module right now and want to port it to ezPublish, I'd like to take full advantage of the advantages of ezPublish and use user-roles for access rights on the items in my module. Let's say my module is called 'My Documents' and I'd like to be able to upload a file. Everybody is able to download the files, some people are able to upload a file and some others are able to upload as well as move the file to the categorie so it's visible to the 'Everybody' user.

What is the best way to deal with these kinds of problems when I'd like to build a ezModule. Would it be wise to create a contentItem and add a field to it 'url' and let the file upload with some own custom php function? Or should I include the file as a related object? (I have no clue how this is done programmatically... but still). And listing them would mean a fetch on the contentItems. Or is it better to implement all this on my own table in the database? How would I go about fetching the data of my own custom type in the templates/module? (sorry, newbie talking here).

Thanks a lot,
Clemens Timmermans
ps: I'm currently going through the EuroFxRef tutorial, and it's very helpful, but I'm trying to learn ezPublish programming and apply it to my own problems, all help is appreciated! thanks.

Ekkehard Dörre

Wednesday 11 May 2005 11:38:36 am

Make a basic install e.g. news with files and you should do all roles, etc. in administration interface without any programming.

Greetings, ekke

http://www.coolscreen.de - Over 40 years of certified eZ Publish know-how: http://www.cjw-network.com
CJW Newsletter: http://projects.ez.no/cjw_newsletter - http://cjw-network.com/en/ez-publ...w-newsletter-multi-channel-marketing

eZ debug

Timing: Jan 20 2025 04:02:38
Script start
Timing: Jan 20 2025 04:02:38
Module start 'content'
Timing: Jan 20 2025 04:02:38
Module end 'content'
Timing: Jan 20 2025 04:02:38
Script end

Main resources:

Total runtime0.3904 sec
Peak memory usage2,048.0000 KB
Database Queries141

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0119 588.8359180.8438
Module start 'content' 0.01190.0071 769.679793.8359
Module end 'content' 0.01900.3714 863.5156523.7344
Script end 0.3904  1,387.2500 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00330.8434200.0002
Check MTime0.00140.3518200.0001
Mysql Total
Database connection0.00701.798410.0070
Mysqli_queries0.325983.46441410.0023
Looping result0.00130.32141390.0000
Template Total0.371195.010.3711
Template load0.00080.193610.0008
Template processing0.370394.839310.3703
Override
Cache load0.00050.130910.0005
Sytem overhead
Fetch class attribute can translate value0.00070.183910.0007
XML
Image XML parsing0.00030.067910.0003
General
dbfile0.01403.5982200.0007
String conversion0.00000.001530.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
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0002 secs