function getid(d){return document.getElementById(d)} function gettag(o,t){return o.getElementsByTagName(t)} function _lowercase(o){return o.toString().toLowerCase()} function _middle(o,l,r){return (o.split(l)[1])?o.split(l)[1].split(r)[0]:''} function _leftback(o,n){return o.substr(0,n)} function _rightback(o,n){return o.substr(o.length-n,n)} function dw(c){document.write(c)} var spacer=''; var _timezones=28800000; var lastmodified='1220243009'; var mgrlink=false; var uris=_lowercase(document.URL); var baseURI=new Array(); baseURI['home']='http://www.fans-web.org/'; baseURI['content']=baseURI['home']+'contentbypermalink'; baseURI['css']=baseURI['home']+'css'; baseURI['js']=baseURI['home']+'js'; baseURI['media']=baseURI['home']+'media'; baseURI['download']=baseURI['home']+'download'; function qsp(p){return _middle(uris+'&','&'+p+'=','&')} function loadjs(s){ upd=(s.split('comment').length>1)?new Date().getTime():lastmodified; upd='&upd='+upd dw('<'+'script src="'+s+upd+'"><'+'/script>')} function addToFavorite(){ if((navigator.appVersion.indexOf("MSIE")>0) && (parseInt(navigator.appVersion)>=4)){ window.external.AddFavorite(baseURI['home'],this.document.title)}} function asmt(n,d){location.href='mailto:'+n+'@'+d} var dbwr=_lowercase(navigator.appName); var isie=(dbwr=='microsoft internet explorer'); var isff=(dbwr=='netscape'); var isother=(!isie && !isff); ishome=(typeof ishome=='undefined')?false:ishome var isview=(uris.split('openview').length>1||ishome); var isdoc=(uris.split('contentbypermalink').length>1); var issrch=(uris.split('searchview').length>1); var ispreview=(uris.split('preview').length>1); viewtitle=uris.split('/')[uris.split('/').length-1].split('.php')[0]+'.php' _start=(qsp('start')=='')?1:qsp('start'); _count=(qsp('count')=='')?10:qsp('count'); _catid=qsp('catid'); _category=(_catid=='')? '':'&catid='+_catid; function status(s,e){s=s.replace(/-/ig,'/');e=e.replace(/-/ig,'/'); var dt=new Date().getTime(); var sd=new Date(s).getTime(); var ed=new Date(e).getTime(); pub=(sd < dt && ed > dt) return pub} var archiveBymonth=['2008_02','2008_03','2008_04','2008_05','2008_06','2008_07','2008_09'].reverse(); function sharchives(){ o=gettag(getid('Archives'),'select')[0]; o.disabled=false; o.options[0]=new Option(calendar_mon[today.getMonth()]+', '+thisyear,'') if(archiveBymonth.length > 0 && archiveBymonth[0].length>6){ for(i=0;i < archiveBymonth.length;i++){ D=archiveBymonth[i].split('_');var yr=D[0];var mn=D[1] sv=baseURI['home']+'contentbymonth.php?openview&catid=' + archiveBymonth[i]; st=calendar_mon[eval(mn-1)] + ', ' + yr; o.options[i]=new Option(st,sv,0,(archiveBymonth[i]==_catid))}}} var _permalink='';var _images=[];var _attachments=[];var _created='';var _modified='';var _pubdate='';var _subject='';var _iscomment='n'; var today=new Date(); var thisyear=(today.getYear() < 1900)? 1900+today.getYear():today.getYear(); var thismon=_rightback('00'+(today.getMonth()+1),2) var navdate=(_catid.length>10||_catid=='')?thisyear+'_'+thismon:_catid var calendar_mon=["January","February","March","April","May","June","July","August","September","October","November","December"] mon_jan='01';mon_feb='02' ;mon_mar='03';mon_apr='04'; mon_may='05';mon_jun='06';mon_jul='07';mon_aug='08'; mon_sep='09';mon_oct='10';mon_nov='11';mon_dec='12'; function shcalendar(){ var dow=new Array('Sun','Mon','Tue','Wed','Thu','Fri','Sat'); var dsow=7;var dsom=31;var cal='';var tdn=0;var Cal; var init_date=navdate.split('_'); Cal=new Date(init_date[0]+'/'+init_date[1]+'/01') var yr=(Cal.getYear()<1900)? 1900+Cal.getYear():Cal.getYear(); var mn=Cal.getMonth(); var wk=Cal.getDay(); Cal.setDate(1); Cal.setMonth(mn); for(index=0;index< Cal.getDay();index++) cal+=' '; for(index=0;index< dsom;index++){ if(Cal.getDate()>index){ wk=Cal.getDay(); if(wk==0){cal+=''} if(wk!=dsow){var dy=Cal.getDate(); cal+=''+dy+'';tdn+=1} if(wk==dsow){cal+=''}} Cal.setDate(Cal.getDate()+1);} cal+=(7-tdn>0)? ' ':'' if(getid('Calendar')){ getid('Calendar').innerHTML='
'+calendar_mon[mn]+', '+yr+'
'+cal+'
SMTWTFS
'}} var profilestr=new Array(); var name=new Array(); profilestr['mgrlink']='Manager'; profilestr['docempty']='previous page'; profilestr['navprev']=''; profilestr['navnext']=''; profilestr['commentinner']='comment?'; profilestr['commenttitle']='Reader Comments'; profilestr['authortitle']=' '; profilestr['updatetitle']='last modified:'; profilestr['more']='more ››'; profilestr['postcommenttitle']='

Post your comment'; profilestr['postcommentname']='›› your name'; profilestr['postcommentemail']='›› email address'; profilestr['postcommenturl']='›› website or blog'; profilestr['postcommentbody']='›› your comment'; profilestr['postcommentbodyalert']='HTML code is not allowed.'; profilestr['postcommentbtn']='post'; profilestr['queryempty']='Search keyword is empty!'; profilestr['myphoto']='My foto'; profilestr['myattachment']='My files'; profilestr['fullstory']='...'; name['chironchou']='chiron.chou'; name['roylee']=''; name['marcchou']=''; name['fans']=''; function timemode(t,m,h){ t=t.toString().replace(/-/ig,'/') tz =(m=='gmt')? 0:_timezones ndt=new Date(new Date(t).getTime()+tz).toGMTString().toString(); i=ndt.split(' ') _wk=_lowercase(i[0]); _m=_lowercase(i[2]) var wk=_wk.substring(0,1).toUpperCase()+_wk.substring(1,3); var dy=_rightback('00'+i[1],2); var mn=_m.substring(0,1).toUpperCase()+_m.substring(1,3); var yr=i[3] var _t=i[4].split(':'); var hrs=(_t[0]>12 && m=='num')? _t[0]-12:_t[0]; var ap=(_t[0]>11)? ' PM':' AM' m_num=yr+'/'+eval("mon_"+_m)+'/'+dy ;m_str=wk+', '+dy+' '+mn+' '+yr;m_gmt=wk+', '+dy+' '+mn+' '+yr v=eval('m_'+m)+' '+_rightback('00'+hrs,2)+':'+_t[1] v+=(m=='num')? ap:'' v+=(m=='gmt')? ':'+_t[2]+' GMT':'' if(h==''||typeof h=='undefined'){dw(v)}else{return v}} function viewisempty(){ if(_totalrec==0) getid('contenttable').innerHTML='

'+profilestr['docempty']+'
'} _prev=eval(_start)-eval(_count);_next=eval(_start)+eval(_count); prevUrl=_prev+'&count='+_count+_category;nextUrl=_next+'&count='+_count+_category; prevlink='' nextlink='' function navlink(){if(isview){p=(_prev<1)?'':prevlink;n=(_next>_totalrec)?'':nextlink; dw(p+n)}} function shatts(t,d,a){ if(a[0]!==''){ attns=a.sort();_pfiles='';_afiles=''; tub=(attns.join(',').split('thumb.gif').length>1); _pCount=0;_aCount=0; for(i=0;i < attns.length;i++){ ext=_rightback(attns[i],4); if(ext=='.jpg'||ext=='.gif'||ext=='.png'||ext=='jpeg'){ if(attns[i]!=='thumb.gif'){ _pfiles+='
'; _pCount++ } } else{ _afiles+=' '+decodeURIComponent(attns[i])+'
'; _aCount++ } } _pfiles=(_pCount>0)?'
'+profilestr['myphoto']+'
':'>')+_pfiles+'
':''; _afiles=(_aCount>0)?'
'+profilestr['myattachment']+'
'+_afiles+'
':''; if((tub && isview) || (tub && issrch)){ dw( '
'+ ((_aCount>0)?'
'+_afiles+'
':'') ); } else{ dw('
'+_pfiles+_afiles+'
') } } } function shft(c,a,m){m=m.replace(/-/ig,'/'); a=(typeof name[a]!='undefined')? profilestr['authortitle']+' '+name[a]+'
':'' c=(typeof catname['cat_'+c]!='undefined')?catname['cat_'+c]+'
':''; var v=c+a+profilestr['updatetitle']+' '+timemode(m,'num','r')+'' dw(v)} function chkSearch(f,srchcounts){var regExp1=/\bfield\b/i;var regExp2=/[(,),<,>,\[,\]]/;var s=f.value; if(trim(s)==''){alert(profilestr['queryempty']);f.focus();return false}else{ if(typeof regExp1.source!='undefined') if(regExp1.test(s)||regExp2.test(s)){ alert('Sorry!\nKeyword can\'t include [, ], (, ), < ? >');f.focus();return false} location.href=baseURI['home']+'contentsearch.php?searchview&query='+encodeURIComponent(s)+'&start=1&count='+srchcounts}} function dl(v,d){dw(''+v+'')} function trim(s){return s.replace(/^\s{1,}/,"").replace(/\s{1,}$/,"")} function mgrlogin(){if(mgrlink){ dw(''+profilestr['mgrlink']+'')}} function setSWF(f,d,w,h){ swfCode='' dw(swfCode) }