Composant Flashfeed

More
14 years 4 months ago #1126 by gorg
Composant Flashfeed was created by gorg
Bonjour et merci pour votre travail :P
Qui n'a pas rêvé d'utiliser joomla comme backend pour Flash ??

J'utilise le composant flashfeed pour créer des fichiers de XML à la volée.
Ces fichiers sont utilisés dans un site 100% flash avec joomla comme backend.
Les utilisateurs qui n'ont pas ou ne prefère pas utiliser le flash sont dirigés vers le template joomla.

Flashfeed fonctionne très bien avec com_content et j'essaye de créer ce qui manque dans flashfeed pour utiliser com_flexicontent

En fait dans flexicontent, j'ai créé un champ image "field16" , celui-ci s'affiche correctement dans le template dans la position image.
Mon but est de baliser le lien de l'image dans mon fichier xml.

Si quelqu'un souhaite m'aider je peux financer les modifs. merci


source flashfeed ici www.youcanjoomla.com/component/jootags/FlashFeed.html j'utilise la dernière version.

mon erreur est à la ligne 91 , je ne sais pas comment récuppérer le contenu du champ field16
Code:
<?php //FLASHFEEDCOPY: Copy this file into package // Check to ensure this file is included in Joomla! defined('_JEXEC') or die( 'Restricted access' ); jimport('joomla.application.component.view'); jimport('joomla.filesystem.file'); class FlexicontentViewItems extends JView { function display($tpl=null) { global $mainframe; // ************* Flashfeed file check *************************** $xmlpath = JPATH_SITE.DS.'components'.DS.'com_flashfeed'.DS.'helpers'.DS.'xml.php'; $constantspath = JPATH_SITE.DS.'components'.DS.'com_flashfeed'.DS.'helpers'.DS.'flexi_constants.php'; if(JFile::exists($xmlpath) || JFile::exists($constantspath)) { require_once $xmlpath; require_once $constantspath; } else { JError::raiseError('ERROR', 'Cannot find Flashfeed files'); } // ************* End Flashfeed file check *************************** $document =& JFactory::getDocument(); $document->setMimeEncoding('text/xml'); echo XMLHelper::getDeclaration(); $xml = new JSimpleXMLElement(XMLConstants::$item); $user =& JFactory::getUser(); $params =& $mainframe->getParams('com_flexicontent'); // Initialize variables $item =& $this->get('Item'); $aparams =& $item->parameters; $params->merge($aparams); $fields = & $this->get( 'Extrafields' ); if (($item->id == 0)) { echo XMLConstants::$ERROR.'Wrong article ID'; } // Check to see if the user has access to view the full article $aid = $user->get('aid'); if ($item->access <= $aid) { // --> Readmore link not supported } else { if (! $aid) { echo XMLConstants::$ERROR.'You dont have permission to view the article'; } else { echo XMLConstants::$ERROR.JText::_('ALERTNOTAUTH'); return; } } $params->set('page_title', $item->title); // Output Article id $node =& $xml->addChild(XMlConstants::$ID); $node->setData($item->id); // Output created $node =& $xml->addChild(XMlConstants::$created); $node->setData($item->created); // Output title $node =& $xml->addChild(XMlConstants::$title); $node->setData($item->title); // Output text $node =& $xml->addChild(XMlConstants::$TEXT); $node->setData($item->text); // Output image $node =& $xml->addChild(XMlConstants::$IMAGE); $node->setData($item->$field16); // -----> ######### mon erreur est ici ########### // output all parameters $parametersNode = $xml->addChild(XMLConstants::$PARAMETERS); $parametersArray = $params->toArray(); foreach($parametersArray as $key => $value) { $node = $parametersNode->addChild($key); $node->setData($value); } echo $xml->toString(); } } ?>

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

More
14 years 4 months ago #1131 by micker
Replied by micker on topic Composant Flashfeed
hello tu as des realisations à nous montrer ?
Merci

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]

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

More
14 years 4 months ago #1195 by gorg
Replied by gorg on topic Composant Flashfeed
En fait, c'est le premier site du genre.
enfin quand je veux dire premier, j'entends le premier qui utilise joomla.
Je n'en suis pas au premier site flash.

La question reste ouverte , je ne penses pas que ce soit très compliqué pour un expert flexi :lol: , je n'ai pas encore compris toute la logique du composant.

Merci pour ton aide si tu as quelques idées.

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

More
14 years 4 months ago #1228 by vistamedia
Replied by vistamedia on topic Composant Flashfeed
Code:
$item->fields['field16']->display
Je pense que c'est ça que tu cherches?
Manu.

FLEXIcontent lead developer.
www.vistamedia.fr web agency and custom development.
www.joomla.fr co-administrator.
Please no PM for support request, use the forum for that!!!

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

More
14 years 4 months ago #1256 by gorg
Replied by gorg on topic Composant Flashfeed
Salut Manu et merci pour ta réponse.
Malheureusement ça ne marche pas , je ne cherche pas à "afficher, -->display" le champ "field16" dans mon template puisque celui-ci s'affiche sans problème.
ça concerne mon balisage XML , le champ "field16" n'apparait pas, j'obtiens une erreur :
<b>Notice</b>: Undefined property: stdClass::$fields in blablabla mon fichier view.xml.php à la ligne 92
Code:
// Output image $node =& $xml->addChild(XMlConstants::$field16); $node->setData($item->fields['field16']->display);

c'est cette dernière ligne qui pose problème , je ne penses pas que -->display soit nécessaire.

En comparaison , voici une ligne qui me retourne une balise xml correcte:
Code:
// Output title $node =& $xml->addChild(XMlConstants::$title); $node->setData($item->title);

voici le contenu de la classe XMLConstants pour info:
Code:
<?php class XMLConstants { /* Content Constants ________________________________________________*/ static $ARTICLE = "article"; static $item = "item"; static $title = "title"; static $table = "table"; static $tableau = "tableau"; static $field16 = "field16"; static $document_type = "document_type"; static $ARTICLES = "articles"; static $created = "created"; static $ARTICLE_URL = "articleurl"; static $ID = "id"; static $CATID = "catid"; static $SECTIONID = "sectionid"; static $COMPONENTHEADING = "componentheading"; static $CONTENTHEADING = "contentheading"; static $CREATED_BY_ALIAS = "createdbyalias"; static $AUTHOR = "author"; static $CREATED_DATE = "createddate"; static $MODIFIED_DATE = "modifieddate"; static $TEXT = "text"; static $INTROTEXT = "introtext"; static $FULLTEXT = "fulltext"; static $CATEGORY = "category"; static $CATEGORY_TITLE = "categorytitle"; static $CATEGORY_IMAGE = "categoryimage"; static $CATEGORY_DESC = "categorydesc"; static $CATEGORY_NUM_ITEMS = "categorynumitems"; static $SECTION = "section"; static $SECTION_TITLE = "sectiontitle"; static $SECTION_DESC = "sectiondesc"; static $SECTION_IMAGE = "sectionimage"; static $PARAMETERS = "parameters"; static $META = "meta"; static $KEYWORDS = "keywords"; static $DESCRIPTION = "description"; static $FRONTPAGE = "frontpage"; static $PAGE_TITLE = "pagetitle"; /* Error Constants ________________________________________________*/ static $ERROR = "There was an error in your call to Joomla: "; } ?>
Mais je suis vraiment bloqué sur ce truc et j'ai besoin d'une main compétente...

Merci encore

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

Moderators: vistamediajoomlacornerggppdk
Time to create page: 0.272 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