Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Capturing Clicked Links from my ASP page

Posted on 2013-01-09
1
Medium Priority
?
226 Views
Last Modified: 2013-01-10
Hi,
I am working on this ASP application and I would like to find a way to capture a clicked link from a page. Let say, I have page A and page B, somebody clicks on a link on page A that directs them to page B. However, I would like to be able to display in a label on page B the link of Page A where the click originated from.

Illustration:

http://abc.com
http://xyz.com

when
0
Comment
Question by:snazaire
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 18

Accepted Solution

by:
Rajar Ahmed earned 2000 total points
ID: 38759680
Try this,
Aspx:
<asp:Label ID="backurl"  runat="server" >Back</asp:Label>

Open in new window


    protected void Page_Load(object sender, EventArgs e)
    {

        backurl.Text = "";
        if (Request.UrlReferrer != null)
        {
            
            backurl.Text = "<a href='" + Request.UrlReferrer.ToString() + "'>" + Request.UrlReferrer.ToString() + "</a>";
            
        }
    }

Open in new window

0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

One of the pain points with developing AJAX, JavaScript, JQuery, and other client-side behaviors is that JavaScript doesn’t allow for cross domain request for pulling content. For example, JavaScript code on www.johnchapman.name could not pull conte…
Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
Suggested Courses

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question