if (this.opener != null) this.opener.focus();

  
var dcCount = 0;
if ( document.cookie.indexOf ("dcCount=") != -1 )
{
  var startAt = document.cookie.indexOf( "dcCount=" ) + 8;
  var endAt = document.cookie.indexOf( ";", startAt );
  if ( endAt == -1 ) endAt = document.cookie.length;
  dcCount = parseInt ( document.cookie.substring ( startAt, endAt ) );
}
dcCount++;
var expires = '';
var dcCountExpiration = new Date();
//dcCount expires in 12 hours
dcCountExpiration.setTime ( dcCountExpiration.getTime() + (1 * 12 * 60 * 60 * 1000) );
expires = ';expires=' + dcCountExpiration.toGMTString();
document.cookie = "dcCount=" + dcCount + expires +";path=/;domain=.washingtonpost.com";

var dcSessionLimit = 0;
if ( document.cookie.indexOf ("dcSessionLimit=") != -1 )
{
  var startAt = document.cookie.indexOf( "dcSessionLimit=" ) + 15;
  var countEndAt = document.cookie.indexOf( "|", startAt );
  var endAt = document.cookie.indexOf( ";", startAt );
  if ( endAt == -1 ) endAt = document.cookie.length;
  if ( ( countEndAt == -1 ) || ( countEndAt > endAt ) ) countEndAt = endAt;
  dcSessionLimit = parseInt ( document.cookie.substring ( startAt, countEndAt ) );
}
dcSessionLimit++;
var newExpDate = new Date();
//session cookie "expires" in 12 hours  ALSO SET IN DCLICKPOPUPMGR.JS!
newExpDate.setTime( newExpDate.getTime() + (1 * 12 * 60 * 60 * 1000));
document.cookie = "dcSessionLimit=" + dcSessionLimit + "|" + ( newExpDate.getTime() ) + "X;path=/;domain=.washingtonpost.com";

popupHasBeenDelivered = true;