Forums

This topic is locked

Hyperlink and new window to reponse.write field

Posted 31 Mar 2003 10:44:31
1
has voted
31 Mar 2003 10:44:31 Sze-Wai Lai posted:
<font face='Verdana'>Hi,

i don't know if anyone can help, but I'd essentially like to be able to allow users to download a job application form from our servers.

I have this page (pre written by someone else) linking to a MS SQL database. The field WelshJobApp contains an http address, like www.rnid.org.uk/JobVacancies/jobref1041.doc
How do i get the WelshJobApp to be a hyperlink and to open up in another window. I know that it needs a href code, but i cannot figure out where the code needs to sit on the third line?

Response.Write "&lt;tr&gt;&lt;td style=""width: 64px;""&gt;&nbsp;&lt;/td&gt;"
Response.Write "&lt;td valign=top&gt;&lt;b&gt;Welsh Application Form&lt;/b&gt;&lt;/td&gt;"
Response.Write "&lt;td valign=top&gt;" & objRS("WelshJobApp" & "&lt;/td&gt;&lt;/tr&gt;"

I'd appreciate any help with this..thanks

Sze
</font id='Verdana'>

Replies

Replied 01 Apr 2003 22:07:29
01 Apr 2003 22:07:29 Scott Burtscher replied:
I'm assuming objRS("WelshJobApp" is how you're returning your info from the DB?

If this is correct, I would try to write the third line like this:

Response.Write"&lt;td valign=top&gt;&lt;a href="" & objRS("WelshJobApp" & ""&gt;&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;"

It would be something like this. I'm not too sure if all of the quotes are written correctly so you may have to try a couple of ways.

Hope this helps
Replied 02 Apr 2003 09:23:01
02 Apr 2003 09:23:01 Sze-Wai Lai replied:
<font face='Tahoma'>Hi, thanks for that, finally got it working on

Response.Write "&lt;td valign=top&gt;&lt;a href='" & objRS("WelshJobApp" & "'
target='_blank'&gt;" & objRS("WelshJobApp" & "&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;"

Sze
</font id='Tahoma'>

Reply to this topic