New Class

Author Message

Dhaval Panchal

Friday 11 February 2011 10:13:46 pm

Hi All,

I need to create new class in ezPublish.

can you please let me know what are the steps?

Thank you

Dhaval Panchal

Franck Magnan

Friday 11 February 2011 10:59:46 pm

Hi Dhaval,

Do you wish to create a content class or a php class ?
If you want to create a content class, you must go to backend administration and copy an existent content class (article, event, ...). Then, you will be able to edit your content class to add fields (text field, email, xml text, object relation ...)

If you want to create a php class, you can do it in making your own extension and declare your new class in "classes" folder of your extension. Then, when your php class is written, you regenerate autoload array to use your class.

Is this explanation helps you?

--
Developer at Open Wide

Dhaval Panchal

Friday 11 February 2011 11:31:02 pm

Hi Franck,

I have create new class from admin interface as follows:

Setting -> Classes -> New class

and i have added few articles in particular class, is it possible to browse it in Scrap URL?

Thank you

Dhaval Panchal

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 18 2025 03:08:06
Script start
Timing: Jan 18 2025 03:08:06
Module start 'layout'
Timing: Jan 18 2025 03:08:06
Module start 'content'
Timing: Jan 18 2025 03:08:07
Module end 'content'
Timing: Jan 18 2025 03:08:07
Script end

Main resources:

Total runtime0.6194 sec
Peak memory usage4,096.0000 KB
Database Queries57

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0057 594.7422152.6094
Module start 'layout' 0.00580.0029 747.351639.3984
Module start 'content' 0.00860.6093 786.7500539.9609
Module end 'content' 0.61790.0015 1,326.710912.2031
Script end 0.6194  1,338.9141 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00330.5351160.0002
Check MTime0.00140.2215160.0001
Mysql Total
Database connection0.00070.117210.0007
Mysqli_queries0.567391.5847570.0100
Looping result0.00050.0872550.0000
Template Total0.592995.720.2965
Template load0.00220.355820.0011
Template processing0.590795.368020.2954
Template load and register function0.00020.027310.0002
states
state_id_array0.00080.126710.0008
state_identifier_array0.00140.224120.0007
Override
Cache load0.00170.2796250.0001
Sytem overhead
Fetch class attribute can translate value0.00080.133020.0004
Fetch class attribute name0.00100.165050.0002
XML
Image XML parsing0.00080.136620.0004
class_abstraction
Instantiating content class attribute0.00000.002160.0000
General
dbfile0.00130.2144210.0001
String conversion0.00000.001340.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
3content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
3content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
5content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1content/datatype/view/ezxmltags/strong.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/strong.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 15
 Number of unique templates used: 7

Time used to render debug report: 0.0001 secs