views:

39

answers:

1

I currently have the following JavaScript function that will take current URL and concatenate it to another site URL to route it to the appropriate feedback group:

function sendFeedback() {
    url = window.location.href;
    newwin = window.open('http://www.anothersite.com/home/feedback/?s=' + url, 'Feedback');
}

Not sure if this is the proper terminology, but I want to mask the URL in the window.open statement to use the URL from the current window.

How would I be able to mask the window.open URL with the original in JavaScript?

+3  A: 

Things you could do:

1- Mask the external site in a html frame inside a document from your site. (for example www.mysite.com/shortUrl/)

2-Send a Location HTTP header (real url will eventually be displayed)

Keep in mind that browsers do their best to show the real address due to phishing concerns.

Ed.C
Thanks for the input. I was looking for a quick and dirty solution in JavaScript, but it sound like more work than I really want to put into it.
Michael Kniskern