Login

flag-uk
SOLUTIONS - DEVELOPER
HomeDocumentationTemplates /  List of Field Attributes
List of field attributes Print E-mail

Call in custom content template any attribute of a field, the value of the field but label, description, maxlenght, style too... This list is not complete.

Attribute Description

General @$jSeblod->field_name->attribute
value return value of the field (most important attribute)
title return title of the field
label return label of the field
description return description of the field
html return html code of the transformed field *
* see html typography, example for a upload image field img src="/*value*" alt="*title*"

Core com_content $this->content->attribute
id return numeric identifier of the content
title return title of the content
alias return alias of the content (SEF)
state return published state (Published=1, Unpublished=0, Archived=1, Trashed=2)
sectionid return numeric identifier of content section
catid return numeric identifier of content category
created return creation date of the content
created_by return numeric identifier of the content author
created_by_alias return username (alias) of the content author
modified return modification date of the content
publish_up return begin publication date of the content
publish_down return end publication date of the content
access return numeric identifier of the content access level
metakey return meta keywords of the content
metadesc return meta description of the content
art_link return link to the content (SEF compatibility)
editart_link return link to the content edition

Special Core com_content $this->content->attribute, attributes available in com_content and some modules but not everywhere
section return section title of the content
category return category title of the content
author return author of the content
usertype return group of the content author
group return access level of the content (see access)
hits return hits of the content
rating return vote number of the content

User Core $this->user->attribute, if user is logged!
name return name of the user
username return username of the user
email return email of the user
usertype return group of the user
registerDate return registration date of the user

Upload Image @$jSeblod->field_name->attribute
value return path of the image (main)
thumb1 return path of the first thumb image
thumb2 return path of the second thumb image
thumb2 return path of the third thumb image

FieldX @$jSeblod->field_name[$i]->attribute
attributes of the repeated field @$jSeblod->field_name[$i]->value
@$jSeblod->field_name[$i]->label
for ( $i = 0, $n = count( @$jSeblod->fieldX_name ); $i < $n; $i++ ) {
echo @$jSeblod->fieldX_name[$i]->attribut;
}
echo @$jSeblod->fieldX_name[0]->attribut;
echo @$jSeblod->fieldX_name[1]->attribut;
...

External Article @$jSeblod->field_name['name_of_a_external_article_field'] ->attribute
all attributes from all fields of the external article

@$jSeblod->field_name['artist_title']->value
@$jSeblod->field_name['artist_title']->label

@$jSeblod->field_name['art_link']->value (generic link to article)

* 2 deep levels: if a current article called a first external article and this first external article called a second external article, you can get in the current article a field value of the second external article.

List File @$jSeblod->field_name->attribute
value return path of the file, all file paths if multiple format
download return link to download the file (supported format: zip, pdf, doc, xls, ppt, exe, gif, png, jpg, jpeg, mp3, wav, mpeg, mpe, mov, avi, flv, tiff, csv, txt, mp4, rar)
downloaded return the number of download, download counter

Group @$jSeblod->field_name[$i]['name_of_a_field_in_the_group'] ->attribute
attributes of the repeated group @$jSeblod->field_name[$i]['name_of_a_field_in_the_group']->value
@$jSeblod->field_name[$i]['name_of_a_field_in_the_group']->label
if external article field in the group @$jSeblod->field_name[$i]['name_of_external_field_in_the_group']['field_name_from_external_article']->attribute
for ( $i = 0, $n = sizeof( @$jSeblod->field_name ); $i < $n; $i++ ) {
echo @$jSeblod->field_name[$i]['name_of_a_field_in_the_group']->attribut;
}
echo @$jSeblod->field_name[0]['name_of_a_field_in_the_group']->attribut;
echo @$jSeblod->field_name[1]['name_of_a_field_in_the_group']->attribut;
...
 

Comments  

 
0 #13 ukulele 2010-07-06 18:28
thank you very much!

i love jseblod :)
 
 
0 #12 jSeblod - Bes 2010-07-06 17:58
@ukulele, it's done
 
 
+2 #11 ukulele 2010-07-06 17:03
hi!
please can you write an explanation for the syntax to the Group (Content Type, Repeatable) field type, how to use in cutom templates?
thanks!
 
 
0 #10 jSeblod - Bes 2010-06-30 22:20
@junite, thanks to open a topic in forum about this.
 
 
0 #9 junite 2010-06-27 20:34
Many of the attribs don´t work in 1.6.2 for me
 
 
+2 #8 传奇私服 2010-05-26 12:33
Good read. There is currently quite a lot of information around this subject on the net and some are most defintely better than others. You have caught the detail here just right which makes for a refreshing change – thanks.
 
 
0 #7 mgonzalez 2010-04-29 13:46
its an option which i can use to disable the template manager from cck, i want to manage my template like defautl options...
 
 
+3 #6 belemus 2010-03-21 21:54
ok
 
 
+2 #5 Jeka 2010-03-09 18:32
Cool guys. I feel the joompower in my heads))))))))
 
 
+7 #4 dragondisastor 2010-02-27 00:51
WoW...
saves lots of time....
 
 
+2 #3 Peter L 2010-02-27 00:12
Much appreciated :)
 
 
+2 #2 Linuus 2010-02-26 08:44
Very nice guys! :)
 

Add comment


Security code
Refresh

Copyright © 2008-2009 Seblod. All rights reserved.

Login On jSeblod CCK website



S5 Register



*
*
*
*
*

Fields marked with an asterisk (*) are required.