How to retrieve items via AJAX

4 years 3 months ago - 4 years 3 months ago #43942 by hede
How can I retrieve the item object with all its properties of a given item id via an AJAX call in my custom module?

cheers

FF on Win10, FLEXIcontent version 3.0.10 on Joomla 3.4

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

4 years 3 months ago #43981 by ggppdk
Hello

use this code :
Retrieving the HTML DISPLAY of FC fields inside 3rd-party code

Just after calling:
FlexicontentFields::getFields($items);

delete code:
FlexicontentFields::getFieldDisplay($item, 'field_name');
...



And use this to output the field values
$item->fieldvalues[field_id];
e.g. with
echo json_encode($item->fieldvalues);
exit;
or the full item with:
echo json_encode($item);
exit;


Regards


-- 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 review. Thanks!

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

4 years 3 months ago #44002 by hede
Thanks! But I face this problem:

Fatal error: Class 'FlexicontentHelperPerm' not found in <b>C:\Users\...\administrator\components\com_flexicontent\models\parentclassitem.php</b> on line <b>977</b>


FF on Win10, FLEXIcontent version 3.0.10 on Joomla 3.4

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

4 years 3 months ago #44053 by hede

FF on Win10, FLEXIcontent version 3.0.10 on Joomla 3.4

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

4 years 3 months ago #44106 by hede
What is this snippet for in http://www.flexicontent.org/site-content/70-develloper-api-field-plugins/247-retrieving-the-html-display-of-fc-fields-inside-3rd-party-code.html ?
$field_names_arr = ...

It does not appear anywere in the code again. So it is not used at all I'd say.

FF on Win10, FLEXIcontent version 3.0.10 on Joomla 3.4

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

4 years 3 months ago #44109 by ggppdk
Hello

it can be used in a field display loop, in your case just ignore it


-- 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 review. Thanks!

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

Moderators: vistamediajoomlacornerggppdk
© 2018 Flexicontent. All Rights Reserved.