Logo 
Search:

Sharepoint Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint       RSS Feeds

Data view for Links list

  Asked By: Brittanie    Date: Apr 08    Category: Sharepoint    Views: 1172

I have added a dataview web part to my site for a Links list found in
another site. When I pull over the ows_url field it includes "url
address, url descripton". I would like it to just show the description
for the link as a hyperlink to the url address. For example, it is
showing http://www.yahoo.com, Yahoo. How do I make it just
show 'Yahoo' as a hyperlink to url address?

Share: 

 

3 Answers Found

 
Answer #1    Answered By: Ramona Solis     Answered On: Apr 08

You will need to edit the xslt for the Data View to parse the field  -
the hyperlink  field type will always return both.

 
Answer #2    Answered By: Harvey Blankenship     Answered On: Apr 08

Is there a document that will show  me how to do this?

 
Answer #3    Answered By: Xiomara Blanchard     Answered On: Apr 08

I created a Links list  and used it as a data  source for a DataViewer Web
Part. As it was a test, both were in the same site.

When I selected the URL field  (as opposed to URL w/menu, etc), it gave me
just the properties you mentioned. When I examine the XSL for the
DataViewer, it shows the following for the display:

<td width="75%" class="ms-vb">
<a href="{substring-before(@URL, ', ')}"><xsl:value-of
select="substring-after(@URL, ', ')" /></a>
</td>

Perhaps you could check your web  part and change the relevant code to the
above? (Make a copy of the original code somewhere first, obviously)

 
Didn't find what you were looking for? Find more on Data view for Links list Or get search suggestion and latest updates.




Tagged: