How ro render specified item?

More
12 years 1 month ago #30156 by ggppdk
Do not try to render the item yet, since i have not tested or verified what is needed to do it,

they way it is done in category view (view.html.php)
(to render the item view of an item)
is to capture PHP output via ob_start() etc

if you want to try this you are on your own, we can not test this now,

plus consider that loading item.css from different template layouts may cause problems


-- 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
12 years 1 month ago #30285 by ggppdk
Try this,
it works, but some changes to it to make it independent have not been tested, it may need corrections:

How to render item view in custom code


-- 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
12 years 1 month ago #30297 by ggppdk
Ok i have decided to add a function
renderItem in class flexicontent_html:

you can use like:
Code:
require_once (JPATH_ADMINISTRATOR.DS.'components/com_flexicontent/defineconstants.php'); JTable::addIncludePath(JPATH_ADMINISTRATOR.DS.'components'.DS.'com_flexicontent'.DS.'tables'); require_once("components/com_flexicontent/classes/flexicontent.fields.php"); require_once("components/com_flexicontent/classes/flexicontent.helper.php"); require_once("components/com_flexicontent/models/".FLEXI_ITEMVIEW.".php"); $itemid = 471; $flexi_html_helper = new flexicontent_html(); $item_html = $flexi_html_helper->renderItem($itemid); echo $item_html;


-- 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.366 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