Tuesday 19 August 2008 5:53:59 am
Hi Fabio, Another approach would be to create a custom template that fetches the imported RSS items. I have not tried this in this particular case, but I expect it would work. Briefly, this would involve the following steps...
1. creating (say) a folder object to represent a content node where you want to display the RSS items again. 2. Creating an override for that folder object - probably somewhere like: /settings/siteaccess/(mysiteaccess)/override.ini.append.php (ref - general overrides: http://ez.no/doc/ez_publish/technical_manual/4_0/templates/the_template_override_system) probably something like:
[repeat_rss_content_folder_number_1]
Source=node/view/full.tpl
MatchFile=repeat_rss_content_folder.tpl
Subdir=templates
Match[node]={nodeID of folder created in step 1}
(ref - override format: http://ez.no/doc/ez_publish/technical_manual/4_0/reference/template_override_conditions) If you want more folders/locations, repeat step 1 and step 2, with different details 3. Create the "repeat_rss_content_folder.tpl" template. Create a new file with a text editor. In this case, I'll assume you're adapting folder.tpl from the ezwebin extension... (ie /extension/ezwebin/design/ezwebin/override/full/folder.tpl). I'm thinking that the thing to do is:
a) replace all "$node" with "$rsssourcenode" b) insert the following fetch function near the top of the template (assuming the node_id of the folder containing the rss items is 1234).
{def $rsssourcenode=fetch( 'content', 'node', hash( 'node_id', 1234) }
(ref fetch functions: http://ez.no/doc/ez_publish/technical_manual/4_0/reference/template_fetch_functions) The purpose of these changes is to fetch and display details of the folder containing your RSS items (and its contained RSS items) instead of the actual node of the folder object you've created. Save the modified folder.tpl file as "repeat_rss_content_folder.tpl" (ie to match the template override created above).
4. Upload the "repeat_rss_content_folder.tpl" file to your eZ installation. for example, /extension/ezwebin/design/ezwebin/override/repeat_rss_content_folder.tpl 5. Clear your eZ site's cache (ie allow the override changes to take effect). If all is well, then visiting the full view for the folder should show all of the RSS items you've imported (or the contents of the node you specified at least). I expect the same process would apply if you wanted to use an embed view instead of a full one, except the "Source=..." line of the override.ini.append.php entry would change accordingly. I hope this helps. Regards. - Paul
|