Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. How To Show A Message Or Page On Clicking Url Link Before Redirecting To An External page

How To Show A Message Or Page On Clicking Url Link Before Redirecting To An External page

Scheduled Pinned Locked Moved ASP.NET
csharphelptutorial
2 Posts 2 Posters 2 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Offline
    H Offline
    hm9
    wrote on last edited by
    #1

    I have a webpage in VB.net with a link so that when users click a url link, it directs them to an external website and it works but I want to add a extra layer so that it shows a message or intermediary page before the external page is loaded to the user. For instance, show a progress bar with delay and message stating "You are leaving this website" before showing or being redirected to the external page. I am using the code below to show the external link. Can you please help with this:

    <a href = "<%# Eval("LinkUrl") %>" target="_blank"> Go to link</a>

    Thanks in advance

    J 1 Reply Last reply
    0
    • H hm9

      I have a webpage in VB.net with a link so that when users click a url link, it directs them to an external website and it works but I want to add a extra layer so that it shows a message or intermediary page before the external page is loaded to the user. For instance, show a progress bar with delay and message stating "You are leaving this website" before showing or being redirected to the external page. I am using the code below to show the external link. Can you please help with this:

      <a href = "<%# Eval("LinkUrl") %>" target="_blank"> Go to link</a>

      Thanks in advance

      J Offline
      J Offline
      JHizzle
      wrote on last edited by
      #2

      I did do something similar quite some time ago which, while probably regarded as crude today, did at least work. Essentially I had an intermediary page that took the target URL as either a query string (which could be the case here) so:

      ["
      target="_blank"> Go to link](<%=[urltoyourintermediarypage] + )

      or as a variable (using an asp:hyperlink control). The page then had a delayed meta-refresh to the target but while it was displayed showed a message warning that they were leaving the site and if they didn't want to continue to hit the cancel which'd just do a javascript history back.

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups