Hi,
How do I display an image that is stored under the data module for my
defined data type?
For example, I have a data type called "product" which has a property called
"logo" (which is of data type binary). The content node created under the
"product" data type was "test".
I tried the following in my jsp:
Content providerNode = null;
providerNode =
MgnlContext.getHierarchyManager("data").getContent("product/test");
String imageURL = providerNode.getNodeData("logo").getHandle() + "/" +
providerNode.getNodeData("logo").getAttribute("fileName") + "." +
providerNode.getNodeData("logo").getAttribute("extension");
However this imageURL doesn't retrieve the image in my jsp when I set it as
the src in the image tag?
I would appreciate it if anyone could help me on this. Thanks.
Cheers,
Rita.
--
View this message in context:
http://www.nabble.com/Displaying-image-from-data-type%27s-property-%28Data-Module%29-tp25870338p25870338.html
Sent from the Magnolia - User mailing list archive at Nabble.com.
----------------------------------------------------------------
For list details see
http://www.magnolia-cms.com/home/community/mailing-lists.html
To unsubscribe, E-mail to: <[email protected]>
----------------------------------------------------------------