문제

I am using SOAP Service connection to connect to a list in another sharepoint in the collection. (Sharepoint 2010)

All of the data comes over fine, except one field which is an image. The URLs all seem to have a , at the end.

<xsl:value-of select="@ows_Icon" disable-output-escaping="yes"/> 
or
<img border="0" src="{@ows_Icon}" />

Both return a URL like the following:

'https://www.site.com/directory/ico_people.jpg,'

Any idea how to remove the , so that I can show the image in the subsite?

도움이 되었습니까?

해결책

This should do it:

<img border="0" src="{substring-before(@ows_Icon, ',')}" />

The comma is there because image fields have 2 fields associated with it, a URL and a description.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 sharepoint.stackexchange
scroll top