I am using Umbraco web forms and using XSLT with it. I have a template where user can select image from the media folder and I want to show that image on the website. I am using the following code to get the URL of the image in XSLT:
I am using "umbracoFile" to get the image URL but its not returning me the URL exaclty but its returning the string "{src: '/media/1002/william1.jpg', crops: []}". and which is why image is not showing up on the page. Anybody know how can I just get the link (i.e. ../media/1002/william1.jpg) so that I can put it in the src.
Get URL of the image in Media folder
I am using Umbraco web forms and using XSLT with it. I have a template where user can select image from the media folder and I want to show that image on the website. I am using the following code to get the URL of the image in XSLT:
I am using "umbracoFile" to get the image URL but its not returning me the URL exaclty but its returning the string "{src: '/media/1002/william1.jpg', crops: []}". and which is why image is not showing up on the page. Anybody know how can I just get the link (i.e. ../media/1002/william1.jpg) so that I can put it in the src.
Sorry, I dont know why code was not posted before.
I solved the problem using substring before and after but will be really good to know if there is a better way to do it. Thanks.
is working on a reply...