Tuesday 27 February 2007 3:50:54 am
I came across this issue today. I have a hidden folder in eZ from which I extract some media content to display on a specific part of my page. The folder MUST be hidden because I don't want the users to see this media content in regular way (content/view/full) but only in that particular part of the page. The media content consist of some nodes that have the ezmedia attribute (some flash animations). So when I try to display that attribute of the fetched nodes I get "Object not available" error. I find out that this is because the nodes i fetched are hidden and the link to the media is something like this: index.php/<mysiteaccess>/content/download/144/814/242_final.swf. So I made a copy of content/datatype/view/ezmedia.tpl template and modified this link to: concat("/",$attribute.content.filepath) which then becomes something like this: /var/<mysiteaccess>/storage/original/application/660933d95758c5b4b7d9848b3b9bfd37.swf And now it works. But I'm wondering is this the safe way to do it since the original template is not made this way? And the difference is not so trivial. The original links calls index.php so the file goes through eZ engine, while the second link bypasses the eZ engine and gives just the file. Are there any reasons why I shouldn't use the second link?
--
Nothing is impossible. Not if you can imagine it!
Hubert Farnsworth
|