Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Shaun E on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

hyperlink targets

Status
Not open for further replies.

gav12345

Programmer
Dec 4, 2003
198
GB
Hi,

I'm quite new to html & I have some hyperlinks that I'm trying to use to pass a variable both to another page (frame) and also to use further down the original page (the variable lets me know which of a number of hyperlinks has been clicked).

The problem is, I can't see how to pass the variable both outside, and within the calling page (passing to another page has been no problem). I found something on the web about using 'onclick' and have tried this but with no success.

The link is as follows:

Code:
<a href=" & _
	chr(34) & "MainFrame.asp?System=" & rsSys("SystemName") & chr(34) & "target=" & chr(34) & _
	"mainframe" & chr(34) & "><h5>onclick=" & chr(34) & parent.frames[0].location.href="SystemListFrame.asp?System="  & _
	rsSys("SystemName") & chr(34) & "target=" & chr(34) & _
	"systemlistframe" & chr(34) & "><h5>" & rsSys("SystemName") & "</h5></a>

Can anyone tell me where I'm going wrong?

Many thanks, Gavin
 
1) you shouldn't be wrapping an h5 with an anchor tag. anchors are inline elements and headers are block elements. inline elements can be inside block elements, but not the other way around.

2) you should post your client-side (view>source) code in the HTML forums.

3) your anchor href and h5 onclick are likely messing eachother up, or at the very lease performing not as expected. are you trying to load two pages in two different frames with a click? what is it that you're trying to achieve?



*cLFlaVA
----------------------------
[tt]"quote goes here"[/tt]
[URL unfurl="true"]http://www.coryarthus.com/[/url]
 
cLFlaVA, thanks for your response...sorry, I've been swamped by other work the last couple days - I'll correct the code as you've suggested and respond to this in full on Monday.

Gavin
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top