My company is required to have "You are now leaving our site" pages for each link on our site leading to an external site. For compliance, it is also required that the process uses an actual page instead of a pop-up. So, when we have visitors on page "A" click the link link, they get redirected to page "B" with a 20 second delay and warning message about leaving the site.

What I don't want to do is have to create a separate page "B" for every external link throughout our site. What can I do to make a single master page "B" that onclick will grab the URL for the external site and auto-populate it into the page "B" master?

My existing code is below.

Current Page "A" HTML:

For more information on widgets, visit <a href="/Page-B/" alt="External Site">Extrernal Site</a>

Current Page "B" HTML:

<script type="text/javascript" language="Javascript">
// <![CDATA[
var x = 20
var y = 1

function startClock(){
x = x-y
setTimeout("startClock()", 1000)
// ]]>
<h1>You Are Now Leaving The Our Business Web Site</h1>
Click the link below to continue or wait 20 seconds to be transferred to:

<a href=""></a>
<p class="smaller">We are providing links to this third party website (<a href=""></a>) only as a convenience and the inclusion of links to the linked site does not imply any endorsement, approval, investigation, verification or monitoring by us of any content or information contained within or accessible from the linked site. Our Business does not control the accuracy, completeness, timeliness or appropriateness of the content or information on the linked site. If you choose to visit the linked site you will be subject to its terms of use and privacy policies, over which Our Business has no control. In no event will Our Business be responsible for any information or content within the linked site or your use of the linked site. By continuing to the linked site you agree to the foregoing.</p>