Define Content Classes in Code

Author Message

Frederik Krautwald

Monday 22 November 2010 9:12:50 am

When an eZ Publish installation is made it automatically creates some Content Classes, such as article, folder, etc. Where are these defined in code?

I want to be able to create a Content Class similar to Article, which automatically gets it Short name from Title in case it isn’t manually entered when published. How is this possible to do?

Frederik Krautwald
Executive Creative Director

Frederik Krautwald

Monday 22 November 2010 11:27:19 am

Sorry, my mad! In no cases is does it happen that a Short name automatically gets assigned from a Content Object’s Name or Title. Should have checked better before posting. Nevertheless, I found out that Content Classes can be imported through packages.

Frederik Krautwald
Executive Creative Director

Romeo Antony

Monday 22 November 2010 12:04:05 pm

Hi, you can easily create your custom classes whatever type that you need from the admin interface.

got to setup tab and click on classes in th leftmenu , you can create your custom classes using different attrubutes that based on your needs. Within a 2 or 3 minutes you can create any complex classes

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 30 2025 00:45:13
Script start
Timing: Jan 30 2025 00:45:13
Module start 'layout'
Timing: Jan 30 2025 00:45:13
Module start 'content'
Timing: Jan 30 2025 00:45:14
Module end 'content'
Timing: Jan 30 2025 00:45:14
Script end

Main resources:

Total runtime0.6796 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.0047 588.1250151.2109
Module start 'layout' 0.00480.0027 739.335936.6563
Module start 'content' 0.00750.6713 775.9922479.0547
Module end 'content' 0.67880.0008 1,255.046911.8516
Script end 0.6796  1,266.8984 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00320.4660160.0002
Check MTime0.00130.1956160.0001
Mysql Total
Database connection0.00050.079710.0005
Mysqli_queries0.638693.9672570.0112
Looping result0.00050.0763550.0000
Template Total0.652896.120.3264
Template load0.00190.279720.0010
Template processing0.650995.776320.3254
Template load and register function0.00010.016510.0001
states
state_id_array0.00070.109010.0007
state_identifier_array0.00090.137720.0005
Override
Cache load0.00160.2379190.0001
Sytem overhead
Fetch class attribute can translate value0.00080.124520.0004
Fetch class attribute name0.00160.233850.0003
XML
Image XML parsing0.00320.469320.0016
class_abstraction
Instantiating content class attribute0.00000.002160.0000
General
dbfile0.00430.6388220.0002
String conversion0.00000.001040.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
3content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1content/datatype/view/ezxmltags/emphasize.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/emphasize.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 12
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs