New kind of articles, same format

More
6 years 8 months ago #72679 by ggppdk
Hello

about modifying the structure of your custom category layout file,
of course you can do anything you want with it to match the desired result

about accessing the raw field values
you can use
Code:
$item->fieldvalues[45]

where 45 is the ID of the field that you want to access its value
e.g. in your case
Code:
if ( !empty($item->fieldvalues[45]) && $item->fieldvalues[45][0] == '1') { echo "value for field no 45 is 1"; }


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...

Please Log in or Create an account to join the conversation.

More
6 years 8 months ago - 6 years 8 months ago #72682 by hervemlam
Thank you both for your answers.

ggppdk wrote: about modifying the structure of your custom category layout file,
of course you can do anything you want with it to match the desired result

OK, but how can I modify the CSS class hierarchy? (I may be too ignorant in CSS, but what defines which css file is used in priority to another?)

about accessing the raw field values
you can use

Code:
$item->fieldvalues[45]

where 45 is the ID of the field that you want to access its value
e.g. in your case
Code:
if ( !empty($item->fieldvalues[45]) && $item->fieldvalues[45][0] == '1') { echo "value for field no 45 is 1"; }

Looks nice, but I'm afraid it doesn't work: like micker just confirmed, it seems to me PHP code cannot be used in "Opening text for Filed". So what could I do? i must admit I have no idea at the moment.

HervE

PHP 8.1.16
Joomla! 4.3.3
FLEXIcontent 4.1.5
Last edit: 6 years 8 months ago by hervemlam.

Please Log in or Create an account to join the conversation.

More
6 years 8 months ago #72686 by ggppdk
Hello

you can use inside
- category_items.php (the layout file of your category view template)
- value_mylayout1.php (a custom layout file for your field)


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...

Please Log in or Create an account to join the conversation.

Moderators: vistamediajoomlacornerggppdk
Time to create page: 0.326 seconds
Save
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Essential
These cookies are needed to make the website work correctly. You can not disable them.
Display
Accept
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline