var empA='<div style="width:180px; height:auto; padding-top:4px; padding-bottom:4px; text-align:center; float:left"><a href="/employer/jobs/';
var empB='" target="_top"><img src="/';
var empC='/button.gif" alt="';
var empD='" style="width:142px; height:43px; margin-top:1px" /></a></div>';
var empW='';
var emp='';

var max     = 20;
var to      = (empCnt <= max) ? empCnt : max;
var already = new Array();
for( var i = 0; i < to; ++ i )
{
    var won=0;
    do{
        won = Math.ceil(Math.random()*empCnt);
    } while( already.indexOf( won ) != -1 );
    already.push(won);
    for(xemp in empx){
        if (empx[xemp].coNum==won){
            var empco = empx[xemp].coKey.substr(0,1) + empx[xemp].coKey.substr(2,1) + empx[xemp].coKey.substr(4,1) + empx[xemp].coKey.substr(6,1)
                if( empco == '3752' )
                {
                    empW = '<div style="width:180px; height:auto; padding-top:4px; padding-bottom:4px; text-align:center; float:left"><a href="http://ad.doubleclick.net/jump/N4789.CareerLink/B5136940.3;sz=142x43;ord=[timestamp]" target="_top" /><img src="http://ad.doubleclick.net/ad/N4789.CareerLink/B5136940.3;sz=142x43;ord=[timestamp]" style="width:142px; height:43px; margin-top:1px" /></a></div>';
                }
                else
                {
                    empW=empA+empco+empB+empx[xemp].coKey+empC+empx[xemp].coName+empD;
                }
            document.write(empW);
        }
    }
}


/*
for(xemp in empx){
 if (empx[xemp].coNum==won){
  var empco = empx[xemp].coKey.substr(0,1) + empx[xemp].coKey.substr(2,1) + empx[xemp].coKey.substr(4,1) + empx[xemp].coKey.substr(6,1)
  empW=empA+empco+empB+empx[xemp].coKey+empC+empx[xemp].coName+empD;
 }
}
document.write(empW);
var won1 = won;
while (won == won1) {
 var won=Math.ceil(Math.random()*empCnt);
}
for(xemp in empx){
 if (empx[xemp].coNum==won){
 var empco = empx[xemp].coKey.substr(0,1) + empx[xemp].coKey.substr(2,1) + empx[xemp].coKey.substr(4,1) + empx[xemp].coKey.substr(6,1)
  empW=empA+empco+empB+empx[xemp].coKey+empC+empx[xemp].coName+empD;
 }
}
document.write(empW);
var won2 = won;
while ((won == won1) || (won == won2)) {
 var won=Math.ceil(Math.random()*empCnt);
}
for(xemp in empx){
 if (empx[xemp].coNum==won){
 var empco = empx[xemp].coKey.substr(0,1) + empx[xemp].coKey.substr(2,1) + empx[xemp].coKey.substr(4,1) + empx[xemp].coKey.substr(6,1)
  empW=empA+empco+empB+empx[xemp].coKey+empC+empx[xemp].coName+empD;
 }
}
document.write(empW);
var won3 = won;
while ((won == won1) || (won == won2) || (won == won3)) {
 var won=Math.ceil(Math.random()*empCnt);
}
for(xemp in empx){
 if (empx[xemp].coNum==won){
 var empco = empx[xemp].coKey.substr(0,1) + empx[xemp].coKey.substr(2,1) + empx[xemp].coKey.substr(4,1) + empx[xemp].coKey.substr(6,1)
  empW=empA+empco+empB+empx[xemp].coKey+empC+empx[xemp].coName+empD;
 }
}
document.write(empW);
var won4 = won;
while ((won == won1) || (won == won2) || (won == won3) || (won == won4)) {
 var won=Math.ceil(Math.random()*empCnt);
}
for(xemp in empx){
 if (empx[xemp].coNum==won){
 var empco = empx[xemp].coKey.substr(0,1) + empx[xemp].coKey.substr(2,1) + empx[xemp].coKey.substr(4,1) + empx[xemp].coKey.substr(6,1)
  empW=empA+empco+empB+empx[xemp].coKey+empC+empx[xemp].coName+empD;
 }
}
document.write(empW);
*/

