c# - WEB - Difficulty in hyperlinks

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • vishalgupta
    New Member
    • Jun 2007
    • 47

    #1

    c# - WEB - Difficulty in hyperlinks

    i want to create a hyerlink that points to some other adress and when clicked on transfers the user to another address.
    e.g. :-
    i have the link : HyperLink1 [DO NOT CLICK THE LINK]
    this points to www.yahoo.com [we can see it in the status bar when we roll our mouse over the link] but when clicked on it should transfer us to www.google.com.
    i am working on asp.net using c#.net and am not able to figure as to how to create this kind on hyperlink...som eone please help.....
  • Plater
    Recognized Expert Expert
    • Apr 2007
    • 7872

    #2
    You would need to use javascript's onmouseover/onmouseout to change the text in the statusbar. Look that up in google and there will be examples.

    Comment

    • camel
      New Member
      • Jan 2008
      • 55

      #3
      Alternatively to the client script approach suggested with JavaScript, if you don't mind a postback then create asp:LinkButton which will look just like a hyperlink visually and use Server.Redirect or Server.Transfer in the Button_Click event to send the User wherever you want them to go.

      Comment

      • vishalgupta
        New Member
        • Jun 2007
        • 47

        #4
        thnks for the replies...javas cript rocks!!!

        Comment

        Working...