469,315 Members | 1,592 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,315 developers. It's quick & easy.

How to pass a value to <a href ="">

Rob
I have values like
<span id = "URL">URL</span>
where the id "URL" is generated by javascript automatically.

I know in JSP, one can pass the value directly like <a href = <%=URL>>

but how do I do this for javascript?

Oct 18 '07 #1
1 1418
Rob wrote on 18 okt 2007 in comp.lang.javascript:
I have values like
<span id = "URL">URL</span>
where the id "URL" is generated by javascript automatically.

I know in JSP, one can pass the value directly like <a href = <%=URL>>

but how do I do this for javascript?
It is just the same in serverside javascript:

<a href = '<% = URL %>'>

For clientside javascript, that seems not your Q, use the DOM.
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Oct 18 '07 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

6 posts views Thread by lecichy | last post: by
5 posts views Thread by Eric A. Forgy | last post: by
1 post views Thread by Christian Schmidbauer | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by zhoujie | last post: by
reply views Thread by suresh191 | last post: by
reply views Thread by harlem98 | last post: by
reply views Thread by harlem98 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.