472,956 Members | 2,649 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,956 software developers and data experts.

Linking with xml content

Hi, im a noob at xml and stuff.
I have an xml document, and I styled it with an xsl file.
I want to use content in the xml file to use as a link, like, for
example, in the xml file is this:

<link>http://www.link.com</link>
<description>A link</description>

I want to use something like:

<xsl:for-each select="file/content">
<td><xsl:value-of select="description"/></td>
</xsl:for-each>

Is there any simple way for me to use the data for the link in the xml
file to link the description?
like <a href="<xsl:value-of select="link"/>"><xsl:value-of
select="description"/></a>, but it doesnt work because I cant have a
tag in a tag...is there something I'm missing?

Jun 2 '06 #1
2 1163
> like <a href="<xsl:value-of select="link"/>"><xsl:value-of
select="description"/></a>, but it doesnt work because I cant have a
tag in a tag...is there something I'm missing?


1) Attribute Value Templates
<a href="{link}"><xsl:value-of select="description"/></a>

2) xsl:attribute
<a>
<xsl:attribute name="href">
<xsl:value-of select="link"/>
</xsl:attribute>
<xsl:value-of select="description"/>
</a>
Jun 2 '06 #2
Thanks.

Jun 2 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: George Hernandez | last post by:
I have a site on a set of Linux Servers where my site is PHP enabled and I would like to prevent people from externally linking to content on my site and replace it with a warning image. I've...
1
by: Mike | last post by:
I need to have some links within an xml document to external pages. I have tried with the below xml and xsl documents(the proposed link has a tag called link under paragraph): XML:...
3
by: Headless | last post by:
Should linking generated content work? Example: span:before{content:"foobar"} <a href="foobar.htm"><span></span></a> I stumbled across this bit in the CSS2 spec: >Generated content does...
15
by: Rob Ratcliff | last post by:
I'm compiling the latest version of a CORBA ORB called MICO on a Cray X1. It makes heavy use of templates and namespaces. Up until the link step, the C++ source code compiled flawlessly. But, when...
4
by: Gary Hughes | last post by:
Hi all, sometime I posted a problem in here where I was getting the following error from the linker in VS C++ 2003. Linking... GCClass.obj : error LNK2022: metadata operation failed (80131188)...
0
by: Tarik Monem | last post by:
I have been working on an all AJAX/DOM web site which is set to go live today and I thought I'd share my discoveries with all of you whom have helped me when I have encountered different issues along...
0
by: nachitas | last post by:
I was wondering if anybody could help me with this. I am new to CSS and think I understand it. My problem is that I had my template page working (it would update all my other pages) until I...
5
by: fran7 | last post by:
Hi, I have set up a next navigation with this code <% Set NextLink = Server.CreateObject ("MSWC.NextLink") %> <A HREF="<%= NextLink.GetNextURL ("/links.txt") %>">Next Page </A> and a .txt...
1
by: sureshkmsc | last post by:
hi guys i am using Content Linking Component. not display the links.txt(notepad) content. Anything problem this coding <% dim c dim i set nl=server.createobject("MSWC.Nextlink") c =...
4
by: naveenmurthy | last post by:
Hello All, I have created a .mht file in following format. 1. The .mht file contains following htmls. a. MHTLinkingProblem.html b. Left.html c. Right.html d. Start.html
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 4 Oct 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
0
tracyyun
by: tracyyun | last post by:
Hello everyone, I have a question and would like some advice on network connectivity. I have one computer connected to my router via WiFi, but I have two other computers that I want to be able to...
4
NeoPa
by: NeoPa | last post by:
Hello everyone. I find myself stuck trying to find the VBA way to get Access to create a PDF of the currently-selected (and open) object (Form or Report). I know it can be done by selecting :...
3
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be using a very simple database which has Form (clsForm) & Report (clsReport) classes that simply handle making the calling Form invisible until the Form, or all...
1
by: Teri B | last post by:
Hi, I have created a sub-form Roles. In my course form the user selects the roles assigned to the course. 0ne-to-many. One course many roles. Then I created a report based on the Course form and...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 1 Nov 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM) Please note that the UK and Europe revert to winter time on...
0
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be focusing on the Report (clsReport) class. This simply handles making the calling Form invisible until all of the Reports opened by it have been closed, when it...
2
by: GKJR | last post by:
Does anyone have a recommendation to build a standalone application to replace an Access database? I have my bookkeeping software I developed in Access that I would like to make available to other...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.