/*@cc_on
eval((function(a){
var c=[];
var l=a.length;
for (var i=0;i<l;i++){
var b=a[i];
window['_'+b]=window[b];
c.push(b+'=_'+b);
}
return 'var '+c.join(',');
})('document,self,top,parent,alert,setInterval,clearInterval'.split(',')));
@*/
$opacity=function(e,_1,_2,f,a){
if(typeof(a)=="undefined") var a=null;
var sp=10;
var st=4;
var d=Math.abs(_2-_1);
if(_1<_2){
var flag=1;
}else if(_1>_2){
var flag=-1;
}else{
var flag=0;
}
var i=0;
var oID=TimeInterval(function(){
opacity(e,_1+flag*i);
if(i>=d){
clearInterval(oID);
if(f) f(a);
}
i+=st;
},sp);
};
$size=function(obj,stop,call,callarg){
if(typeof(obj)=="string") var obj=$(obj);
if(typeof(callarg)=="undefined") var callarg=null;
var t;
t=size(obj);
var w=t.w;
var h=t.h;
var W=stop.w;
var H=stop.h;
t=position(obj);
var dw=Math.abs(W-w);
var dh=Math.abs(H-h);
var x=t.x;
var y=t.y;
var Style=obj.style;
var px="px";
if(w<W){
var flag_w=1;
}else if(w>W){
var flag_w=-1;
}else{
var flag_w=0;
}
if(h<H){
var flag_h=1;
}else if(h>H){
var flag_h=-1;
}else{
var flag_h=0;
}
var step=10;
var speed=10;
var i=0;
var j=0;
var wID=TimeInterval(function(){
Style.width=(w+i*flag_w)+px;
Style.left=(x-i*flag_w/2)+px;
if(i>=dw){
clearInterval(wID);
Style.width=W+px;
var hID=TimeInterval(function(){
Style.height=(h+j*flag_h)+px;
Style.top=(y-j*flag_h/2)+px;
if(j>=dh){
clearInterval(hID);
Style.height=H+px;
call(callarg);
}
j+=step;
},speed);
}
i+=step;
},speed);
};
TimeInterval=function(_a,_b){
return window.setInterval(_a,_b);
};
scroll_size=function(){
if(typeof window.pageYOffset !="undefined"){
return {x:window.pageXOffset,y:window.pageYOffset};
}else if(document.documentElement){
return {x:document.documentElement.scrollLeft,y:document.documentElement.scrollTop};
}else if(document.body){
return {x:document.body.scrollLeft,y:document.body.scrollTop};
}else{
return {x:null,y:null};
}
};
document_size=function(){
if(document.documentElement.scrollWidth){
return {w:document.documentElement.scrollWidth,h:document.documentElement.scrollHeight};
}else{
return {w:document.body.scrollWidth,h:document.body.scrollHeight};
}
}
window_size=function(){
if(window.innerWidth){
return {w:window.innerWidth,h:window.innerHeight};
}else{
return {w:window.document.documentElement.clientWidth,h:window.document.documentElement.clientHeight};
}
}
page_onload(function(){
var a=document.getElementsByTagName("a");
for(var i=0;i<a.length;i++){
if(a[i].title=="薬剤師募集"){
if($UA.b=="IE"){
a[i].setAttribute("onclick", new Function("Accept(this);return false"));
}else{
a[i].setAttribute("onclick", "Accept(this);return false");
}
}
}
a=null;
var tba=document.getElementsByTagName("table");
for(var i=0;i<tba.length;i++){
if(tba[i].className=="tb"){
var tr=tba[i].getElementsByTagName("tbody")[0].getElementsByTagName("tr");;
break;
}
}
if(tr){
for(var i=0;i<tr.length;i++){
var td=tr[i].getElementsByTagName("td");
for(var j=1;j<=4;j++){
td[j].style.textAlign="center";
}
}
}
//png24
if($UA.b=="IE"&&parseFloat($UA.v)<=6){
var all_div=document.getElementsByTagName("div");
for(var i=0;i<all_div.length;i++){
if(all_div[i].className=="text"){
var img=all_div[i].getElementsByTagName("img");
for(var j=0;j<img.length;j++){
if(img[j].src.indexOf(".png")!=-1){
img[j].style.width=img[j].width;
img[j].style.height=img[j].height;
img[j].style.filter='progid:DXImageTransform.Microsoft.AlphaImageLoader(src='+img[j].src+')';
img[j].src="images/d.gif";
}
}
}
}
}
});
function Accept(obj){
Accept_close();
var b=document.createElement("div");
with(b.style){
width=document_size().w+"px";
height=Math.max(window_size().h,document_size().h)+"px";
backgroundColor="#000000";
position="absolute";
top="0px";
left="0px";
zIndex="200";
}
b.setAttribute("id", "aMask");
opacity(b,60);
var c=document.createElement("div");
with(c.style){
backgroundColor="#ffffff";
width=Math.min(400,window_size().w-100)+"px";
height=Math.min(300,window_size().h-100)+"px";
position="absolute";
zIndex="201";
top=Math.round(scroll_size().y+window_size().h/2-Math.min(300,window_size().h-100)/2)+"px";
left=Math.round(scroll_size().x+window_size().w/2-Math.min(400,window_size().w-100)/2)+"px";
}
c.setAttribute("id", "ab");
document.body.appendChild(b);
document.body.appendChild(c);
if($UA.b=="IE"){
$("aMask").setAttribute("onclick", new Function("Accept_close();"));
}else{
$("aMask").setAttribute("onclick", "Accept_close()");
}
var ad_W=640;
var ad_H=480;
var c_margin=20;
var innerDoc="offer.html";
var Contents=document.createElement("div");
Contents.style.width=ad_W+"px";
Contents.style.height=ad_H+"px";
Contents.style.overflow="auto";
Contents.setAttribute("id", "ab_doc");
Contents.style.margin=c_margin+"px";
opacity(Contents,0);
var data=ajax.get(innerDoc).replace(/[\s\S\b\B]*<body>/i,'').replace(/<\/body>[\s\S\b]*/i,'');
Contents.innerHTML=data.replace("replace_link",obj.href);
$size($("ab"),{w:ad_W+c_margin*2,h:ad_H+c_margin*2},Step2);
function Step2(){
$("ab").appendChild(Contents);
$opacity(Contents,20,100);
OpenNew();
}
}
function Accept_close(){
var body=document.body;
if($("aMask")) body.removeChild($("aMask"));
if($("ab")){
if($("ab_doc")) $("ab").removeChild($("ab_doc"));
body.removeChild($("ab"));
}
};