#!/usr/local/bin/bee -s eee=yes; path=""; s=""; ss={}; side=no;pass=no;password="" #-- COLORSandSTUFF============= AA="#DDDDFF" #table color BB="ffffff" #page background color CC="000000" #body text color DD="blue" #link color EE="000066" #visited link color FF="red" #active link color FFF="33FFFF" #hover link color GG="250" #width of left frame HH="Welcome to the Abagyan Lab" #window title II="bg.gif" #background image [set to "" for no image] # ICONS are taken from the following files in the: # icon-----------regular---------mouseover--------mousedown------inactive # # Previous: prev.gif prev_f2.gif prev_f3.gif previn.gif # Next: next.gif next_f2.gif next_f3.gif nextin.gif # Up: up.gif up_f2.gif up_f3.gif upin.gif # Print: print.gif print_f2.gif print_f3.gif printin.gif #=========================== doargs2() #process args . . . " -- pretx: creating anchor table . . ." T=tablefiles(s) " -- pretx: creating table of keywords . . ." K=tablekeys(T, s, eee) " -- pretx: writing table of contents . . ." t=T side?toc2(t, path):toc(t, path) delete t " -- pretx: replacing links to filename#link . . ." linker(T, s) " -- pretx: writing indexx.htm . . .\n" indexx(K, side, path) " -- pretx: creating javascript search file searchh.htm. . ." java(K, path) " -- pretx: finalizing . . ." finalize(T,K) " --To continue the splitting process please run:" " tx2htm .pre.tx >! .htm" " splittx .htm -[optional arguments (see help)]" quit #tablefiles - 57 #tablekeys - 162 #toc - 223 #toc2 - 274 #linker - 330 #indexx - 411 #HtmlHeader - 530 #java - 596 #helpp - 624 #style - 763 #keyerrspace - 778 #Up - 697 #Spacer - 703 #doargs - 713 #finalize - 752 #HtmlHeaderf - 762 #___________________________________________________________________________ #___________________________________________________________________________ #___________________________________________________________________________ #___________________________________________________________________________ function tablefiles(s) # BUG in args= does not match rita{}{password=..} T=table({0}///{"Filenames"}///{"Anchors"}///{"Titles"}///{1}///{"Big Titles"}///{"Args"}) num=0 s=Replace(s, '(\{.*?\})', '\1 ') #HEADING MATCH name=string(Match(s,'>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\nh([1234])--(.*?)\n', field=1, global)) title=string(Match(s,'>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\nh([1234])--(.*?)\n', field=8, global)) keys=string(Match(s,'>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\nh([1234])--(.*?)\n', field=2, global)) level=integer(Match(s,'>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\nh([1234])--(.*?)\n', field=7, global)) args=string(Match(s,'>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\nh([1234])--(.*?)\n', field=3, global)) name=Trim(name) title=Trim(title) keys=Trim(keys) args=Trim(args) ss=Split(s, '>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\nh([1234])--(.*?)\n', field=3) #split s into ss rbot=string(Match(ss[1],'rightfooter:\s*?\{(.*?)\}':n field=1)) rtop=string(Match(ss[1],'rightheader:\s*?\{(.*?)\}':n field=1)) write append rtop '.pretx.ibi' write append rbot '.pretx.ibi' d=0 if level>4 | level < 1 then anc_errors=level >4 | level < 1 >> Index "There are " + Nof(anc_errors) + " improper file levels in your file" "This script only supports levels of 1 through 4" "See '.preerr.tx' for list of incorrect file levels" ero="\n\n\nImproper Anchors:\n" ero+="==============================\n" ero+=title[anc_errors] >>Sarray>>Sum(@,"\n") write append string ero '.preerr.tx' if (eee) quit "Please correct error and run again." endif for i=1,Nof(name) #LOOP THROUGH ALL FILES num+=1 if (Nof(args[i])>1) then args[i]=args[i][2:Nof(args[i])-1] endif #---------------- if(Nof(title[i])<26) then #IF TITLE TOO LONG T//={num,name[i],"",title[i],level[i], title[i], args[i]} else x=Split(keys[i], ',') #THEN USE 1ST KEYWORD x=Trim(x) T//={num,name[i],"",x[1],level[i], title[i], args[i]} endif #---------------- #FIND ALL !-, !_ ANCHORS IN THAT FILE vname=string(Match(ss[i+1], '>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\s*\n\!([\-\_])(.*?)\n', field=1, global)) vkeys=string(Match(ss[i+1], '>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\s*\n\!([\-\_])(.*?)\n', field=2, global)) vtitle=string(Match(ss[i+1], '>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\s*\n\!([\-\_])(.*?)\n', field=8, global)) vlevel=string(Match(ss[i+1], '>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\s*\n\!([\-\_])(.*?)\n', field=7, global)) vargs=string(Match(ss[i+1], '>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\s*n\!([\-\_])(.*?)\n', field=3, global)) vname=Trim(vname) vtitle=Trim(vtitle) vkeys=Trim(vkeys) for j=1, Nof(vname) lev=4 if (vlevel[j]=="-") then lev=3 endif vname[j]=T[d+i+1].B+".htm#"+vname[j] #---------------- if(Nof(vtitle[j])<26) then T//={num,vname[j],"",vtitle[j],lev,vtitle[j], args[j]} else v=Split(vkeys[j], ',') v=Trim(v) T//={num,vname[j],"",v[1],lev,vtitle[j], args[j]} endif #---------------- endfor d+=Nof(vname) endfor T.A=T.A>>Sarray lev1=0 lev2=0 lev3=0 lev4=0 for mum=2, Nof(T) #generate level numbering if T[mum].E==1 then lev1+=1 T[mum, "A"]=lev1 elseif T[mum].E==2 then if (T[mum-1].E==1) lev2=0 lev2+=1 T[mum, "A"]=lev1 + "." + lev2 elseif T[mum].E==3 then if (T[mum-1].E<3) lev3=0 lev3+=1 T[mum, "A"]=lev1 + "." + lev2 + "." + lev3 elseif T[mum].E==4 then if (T[mum-1].E<4) lev4=0 lev4+=1 T[mum, "A"] = string(lev1 + "." + lev2 + "." + lev3 + "." + lev4) endif endfor write append T '.pretx.ibi' T=T.B!~"#" return T endfunction #___________________________________________________________________________ function tablekeys(T, s, eee) keyerrcheck(s, eee) Paths =Match(s,'\>\>\>(\S+?)\{(.+?)\}', field = 1, global=yes) Keys =Match(s,'\>\>\>(\S+?)\{(.+?)\}', field = 2, global=yes) " -- pretx: "+ Nof(Paths) + " anchors found..." K=table({""}///{"Paths"}///{"Numbers"}) for i=1,Nof(Paths) #Put Keys and Paths together into table K//={Keys[i], Paths[i], ""} endfor for i=2, Nof(K.A) #SPLIT THE KEYWORD LISTS AND INSERT EXTRAS h=Split(K[i].A, ',') for f=2, Nof(h) #for every comma section K=K[1:i] // {Trim(h[f]), K[i].B, K[i].C} // K[i+1:Nof(K.A)] #insert the new entry in the right spot endfor K[i, "A"]=Trim(h[1]) endfor q={""} sss=Split(s,'>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\nh([1234])--(.*?)\n', field = 1) #SPLIT AND STORE IN ARRAY TO FIND ANCHOR FILES K.B=Trim(K.B) T.B=Trim(T.B) for i=2, Nof(K.A) if(Nof(T.B==K[i].B)>0) then #IF ANCHOR IS A FILENAME l=T.B==K[i].B K[i,"B"]=K[i,"B"]+".htm" #just add '.htm' to make it a path K[i,"C"]=l[1].A #add the file number for the index links else #IF ANCHOR IS MID PAGE ANCHOR for p=2, Nof(sss) #LOOP THROUGH EACH PAGE q={""} if (sss[p]~(">>>"+K[i].B)) then #IF ANCHOR IS IN THAT PAGE #add anchor under the file name for later anchor-file reference if(Nof(q==K[i].B)==0) then #if not duplicate if(T[p,3]) then #if there is already anchor then add comma T[p,3]+=', ' + K[i].B q//=K[i].B else #if first anchor then don't add comma T[p,3]=K[i].B q//=K[i].B endif #end comma check endif #end duplicate anchor check K[i,"B"]=T[p].B+".htm#"+K[i].B #make file name - anchor path K[i,"C"]=T[p].A #add the file number for the index links endif endfor endif endfor write T '.q.ibi' write append K '.q.ibi' return K endfunction #___________________________________________________________________________ function toc(T, path) T=T.B!~"#" r="" r+='
" + Upn(T[o].D) + "
" else r+= "" + Upn(T[o].D) + "
" endif else while(o<=Nof(T.E) & T[o].E==4) if (T[o].B~"#") then r+="" + Upn(T[o].D) + " | " else r+="" + Upn(T[o].D) + " | " endif o+=1 endwhile if(r[Nof(r)-1]=="|") then r=r[1:Nof(r)-2] endif r+="
\n" o-=1 endif o+=1 endwhile r+="

" write string HtmlHeaderf()+Style()+r + "" path + "/" + "toc.htm" endfunction #___________________________________________________________________________ function toc2(T, path) T=T.B!~"#" r="" top=string(Match(ss[1],'leftheader:\s?\{(.*?)\}':n field=1)) r+=top r+='" + Upn(T[o].D) + "
\n" r+=Spacer(2) G=T[o].E o+=1 while((o<=Nof(T)) & (T[o].E>=G)) if(T[o].E<3) then if (T[o].B~"#") then r+="" + Upn(T[o].D) + " | " else r+="" + Upn(T[o].D) + " | " endif endif o+=1 endwhile if(o<=Nof(T)) then r+="\n" endif endif #end Glossary if (o<=Nof(T)) then if (T[o].B~"#") then r+= T[o].A + " " + Up(T[o].D) + "
\n" else r+= T[o].A + " " + Up(T[o].D) + "
\n" endif if T[o].E==1 then r+="
\n" endif endif endif o+=1 endwhile r+="

" bot=string(Match(ss[1],'leftfooter:\s?\{(.*?)\}':n field=1)) r+=bot write string HtmlHeader()+ Style()+ r + "" path + "/" + "toc.htm" endfunction #___________________________________________________________________________ function linker(T, s) anc = Match(s,'\>\>\>(\S+?)[\s\{]',field=1,global) >> Sarray t=anc///Iarray(Nof(anc) 1) sort t.anc Group(t,{"anc"}).Sum_A != 1 => anc_errors if anc_errors then #CHECK FOR DUPLICATE ANCHORS ------- "There are " + Nof(anc_errors) + " duplicate anchors in your file." "See '.preerr.tx' for list." ero="Duplicate Anchors:\n" ero+="==============================\n" ero+=anc_errors.anc >> Sum(@, "\n") write append string ero '.preerr.tx' if (eee) quit "Please correct error and run again." endif fn=Match(s,'>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\nh([1234])--(.*?)\n', field = 1, global) >> Sarray >> Trim k=Match(s,'>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\nh([1234])--(.*?)\n', field = 2, global) >> Sarray >> Trim lv=Match(s,'>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\nh([1234])--(.*?)\n', field = 7, global) >> Iarray tt=Match(s,'>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\nh([1234])--(.*?)\n', field = 8, global) >> Sarray >> Trim ix=Match(s,'>>>(.*?)\s*\{(.*?)\}\s*((\{(.*?)\})|(\s*))\nh([1234])--(.*?)\n', global) % Index % function(x) x[1] ix >> Iarray => ix toc_errors = lv-(lv[2:$]//4) > 3 >> Index if toc_errors then #CHECK FOR GOOD LEVEL STRUCTURE ------- "Your level structure is inconsistent in " + Nof(tt[toc_errors]) + " locations." "See '.preerr.tx' for list." ero="\n\n\n\nLevel structure errors:\n" ero+="==============================\n" ero+=toc_errors >> tt[@] >> Sum(@, "\n") write append string ero '.preerr.tx' if (eee) quit "Please correct error and run again." endif ix_all=Match(s,'\>\>\>(\S+?)[\s\{]', global) % Index % function(x) x[1] ix_all>>Iarray=>ix_all T=fn///k///tt///lv///ix se=Sarray(Nof(anc)) Tf=T T//=anc///se///se///se///ix_all sort T.ix T=Group(T {"ix"} {'fn' 'k' 'tt' 'lv'} {Max, Max, Max, Max}) T///=Sarray(Nof(T)) for i=1, Nof(T) if (T[i].Max_tt!="") then parent=i T[i, "A"]=T[parent].Max_fn + ".htm" else T[i, "A"]=T[parent].Max_fn + ".htm#" + T[i].Max_fn endif endfor #REPLACE IMPLIED AND NON-IMPLIED LINKS ------- s=Replace(s, '\`' + T.Max_fn + '\s*\{(.*?)\}\s*\{pop\}','\1') #pop links s=Replace(s, '\`' + T.Max_fn + '\s*\{(.*?)\}\s*\{pop1\}','\1') #pop links s=Replace(s, '\`' + T.Max_fn + '\s*\{(.*?)\}', '\1') #all links with title s=Replace(s , '\`' + T.Max_fn + '(\s)', '' + T.Max_fn + '\1') # all links with implied title #------- lnk_error=Match(s, '\`(\S+)', global) >> Sarray lnk_error=lnk_error!~'\/' if (lnk_error) then Nof(lnk_error) + " links do not have corresponding anchors." "See '.preerr.tx' for list." ero="\n\n\n\nEmpty Links:\n" ero+="==============================\n" lnk_error >> Sarray =>ooo ooo///ooo=>O O=Group(O, "ooo") ero+= O.ooo >> Sum(@, "\n") write append string ero '.preerr.tx' if (eee) quit "Please correct error and run again." endif s=Replace(s, '\{inserttoc\}', '') write string s '.pre.tx' #write file to pre.tx for conversion to HTML endfunction #___________________________________________________________________________ function indexx(K, side, path) index= HtmlHeader() index+= Style() if !side then index+='" + K.C + "" #change paths into links sort K.D K.C #sort by keyword K >> Unique => K for o=1, Nof(K)-2 #put together multiple links for one keyword while K[o].A==K[o+1].A K[o, "B"]+=", " + K[o+1].B delete K[o+1] endwhile endfor index+= "

Index

" for abc=65, 90 if(K.D[,1]~string(char(abc))) then index+=" "+ char(abc) +" |" else index+=" " + char(abc) +" |" endif endfor u=1 fir=1 while(u123)) u+=1 endwhile u-=1 if(u!=0) then I=K[1:u] index+="

" + "Symbols" + "


" fir=u+1 zz="notthislamn" for o=1, Nof(I) if(Nof(I.A[o]~'\.')>0) then oo=Split(I[o, "A"], '\.') if(oo[1]!=zz) then I=I[1:o-1] // {oo[1], "","",""} // {Spacer(4)+oo[2], I[o].B, I[o].C, Upn(I[o].D)} // I[o+1:Nof(I)] zz=oo[1] else I.A[o]=Spacer(4) + oo[2] endif elseif(I.B[o]!="") then zz=I.A[o] endif endfor jj=integer(Ceil(real(Nof(I))/2)) for o=1, jj index+="\n" index+="" if (o*2<=Nof(I)) then index+="\n" index+="" endif endfor index+="
" + I[o].A + " " + I[o].B + " " + I[o+jj].A + " " + I[o+jj].B + "
" endif for u=fir+2, Nof(K) if (K[u, "D"][1]!=K[u-1, "D"][1]) then I=K[fir:u-1] fir=u zz="notthislamn" for o=1, Nof(I) if(Nof(I.A[o]~'\.')>0) then oo=Split(I[o, "A"], '\.') if(oo[1]!=zz) then I=I[1:o-1] // {oo[1], "","",""} // {Spacer(4)+oo[2], I[o].B, I[o].C, Upn(I[o].D)} // I[o+1:Nof(I)] zz=oo[1] else I.A[o]=Spacer(4) + oo[2] endif elseif(Nof(I[o, "A"])>4 & I[o, "A"][1:6]!=Spacer(1) & I[o, "B"]!="") then zz=I.A[o] endif endfor index+="

" + Toupper(K[u-1].A[1]) +"


" index+="" jj=integer(Ceil(real(Nof(I))/2)) for o=1, jj index+="\n" index+="" if(o*2<=Nof(I)) then index+="\n" index+="" endif endfor index+="
" + I[o].A + " " + I[o].B + " " + I[o+jj].A + " " + I[o+jj].B + "
" endif endfor write string index path + "/indexx.htm" endfunction #___________________________________________________________________________ function HtmlHeader() html='' + "\n" html+='' + "\n" html+='' + "\n" html+='' + "\n" html+=' directory (./man by default):\n" "1. Replaces links -> .pre.tx" "2. Generates Table of Contents -> toc.htm" "3. Generates Index -> indexx.htm" "4. Generates js file forsearch -> java.js" "-------------------------------------" "Error output:\n" "1. Duplicate anchornames" "2. Bad table structure" "3. Empty links" "All errors are written to '.preerr.tx'" "-------------------------------------" "Flags:\n" "-h, --help: displays this help text" "-e, --err: continues to run despite errors" "-s, --side: limits toc to 2 levels (for frame version) (inserts contents of 'top.htm' at the top)" "-p, --path[=]: output path (defaults to 'man'). Use '*' to use most recent path." "-w, --warn: runs only tests on tx file and reports warnings" "-------------------------------------" "Heading syntax:\n" " >>>{[keyword1,keyword2,keyword3...]}[argument1 argument2 argument3...]" " h-- \n" "--Arguments:\n" "inserttoc: Prints a list of the next-level subheadings before the body of the page" "Example:" ">>>showclr{show colors,color show}inserttoc" "h2-- This is a story about colors and how to show them\n" "will create file showclr.htm, add show colors and color show to Index and generate a local table of contents" "-------------------------------------" "Mid-Page Anchor syntax:\n" " >>><anchorname>{[keyword1,keyword2,keyword3]}\n" "E.g.\n>>>pointofint{point of interest}" "-------------------------------------" "Link syntax:\n" " full form: `<anchorname>{Title} , e.g. `Sin{Sinus funcion} " " short form: `<anchorname> , e.g. `Sin is equivalent to `Sin{Sin}\n" "To continue process run 'tx2htm' with '.pre.tx' as the input. " "Then run the 'splittx' bee-script on resulting htm file to split.\n\n" "-------------------------------------" "Header/Footer Syntax:\n" "Optional header and footers for the left and right frames can be include in your original tx file before the first header" "using the following syntax:\n" "leftheader:" "{" "<left frame header content>" "}" "rightheader:" "{" "<right frame header content>" "}" "leftfooter:" "{" "<left frame footer content>" "}" "rightfooter:" "{" "<right frame footer content>" "}" ">>>frstfile{first file}" "h1-- This is the First File" endfunction #___________________________________________________________________________ function Style() return << END <Style type="text/css"> <!-- A:link { COLOR: blue;} A:visited { COLOR: "000066"; TEXT-DECORATION: none;} A:active { COLOR: red; TEXT-DECORATION: none } A:hover { COLOR: black; TEXT-DECORATION: none;} --> </Style> END endfunction #___________________________________________________________________________ function keyerrcheck(s, eee) allps=Match(s,'\>\>\>(\S*?)\s*[\{\s]', field = 1, global=yes) >> Sarray someps=Match(s,'\>\>\>(\S+?)\s*\{(.+?)\}', field = 1, global=yes) >> Sarray sort allps sort someps if (Comp(allps,someps)[3]>>Nof>0) then Nof(allps)-Nof(someps) + " anchor(s) do not have correctly formatted key fields and will not be recognized by the linker." "See '.preerr.tx' for list of incorrect anchors." ero="\n\n\nIncorrect Anchors:\n" ero+="=======================\n" ero+=Comp(allps,someps)[3] >> Sarray >> Sum (@, "\n") write append string ero '.preerr.tx' if (eee) quit "Please correct error and run again." endif endfunction #___________________________________________________________________________ function Up(s) return (Split(s) % function(x) (x=='and'|x=='or'|x=='of'|x=='the')?x:Toupper(x,1))>>Sum(@," ") endfunction function Upn(s) return s endfunction #___________________________________________________________________________ function Spacer(o) iii="" for milk=1, o iii+=" " endfor return iii endfunction #___________________________________________________________________________ function doargs2() write string "" '.preerr.tx' if (!shell.ParseArgs("ewsp",{"err","side","warn","path"}) | Nof(shell.args)>1) then #PROCESS ARGS helpp() quit endif side=shell.options.s | shell.options.side #SIDE FLAG CHECK if (shell.options.e | shell.options.err) then #ERROR FLAG CHECK eee=no endif if(! shell.options.path) shell.options.path=shell.options.p #PATH SET if (shell.options.path=="*") then read '.pretx.ibi' shell.options.path=path endif if(! shell.options.path) shell.options.path= "man" path=shell.options.path if( !(file(path).ok) ) unix mkdir $path write path ".pretx.ibi" write append AA ".pretx.ibi" write append BB ".pretx.ibi" write append CC ".pretx.ibi" write append DD ".pretx.ibi" write append EE ".pretx.ibi" write append FF ".pretx.ibi" write append FFF ".pretx.ibi" write append GG ".pretx.ibi" write append HH ".pretx.ibi" write append II ".pretx.ibi" if(Nof(shell.args)==0) shell.args[1] = "stdin" #STANDARD INPUT SET + APPEND FILED for i=1,Nof(shell.args) read string shell.args[i] name="aaa"; s+= aaa; endfor Replace(s, '\{\}', '{ }')>>Replace(@, '\n// .*',"") => s # get rid of comments if ( shell.options.w | shell.options.warn ) then #WARN FLAG OPTION T=tablefiles(s) keyerrcheck(s, eee) linker(T,s) quit endif endfunction #___________________________________________________________________________ function finalize(T, K) write append K '.pretx.ibi' read string '.preerr.tx' name='tryy' if !tryy then write string "NO ERRORS in found in input." '.preerr.tx' " -- NO ERRORS in found in input." endif show tryy endfunction #___________________________________________________________________________ function HtmlHeaderf() return <<END <html> <head> <script language="JavaScript"> <!-- function search() { k=document.form1.text1.value; document.cookie=""; document.cookie= "wm_javascript=search::" + escape(k) window.location="searchh.htm"; } if (navigator.appName!="Netscape") { document.writeln('<style type="text/css">') document.writeln(" body {") document.writeln(" margin-left: 8%;") document.writeln(" margin-right: 8%;") document.writeln(" font-family: sans-serif;") document.writeln(" }") document.writeln(" h2 { margin-left: -3% }") document.writeln(" h3,h4,h5,h6 { margin-left: -2% }") document.writeln(" pre {") document.writeln(" font-weight: normal;") document.writeln(' white-space: pre; font-family: "Courier New", monospace;') document.writeln(" }") document.writeln(" tt {") document.writeln(" font-weight: normal;") document.writeln(' white-space: pre; font-family: "Courier New", monospace;') document.writeln(" }") document.writeln(" em { font-style: italic; font-weight: bold }") document.writeln(" strong { text-transform: uppercase; font-weight: bold }") document.writeln("</style> ") } function MM_findObj(n, d) { //v3.0 var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n]; for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document); return x; } function MM_swapImage() { //v3.0 var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3) if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];} } function MM_swapImgRestore() { //v3.0 var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc; } function MM_preloadImages() { //v3.0 var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array(); var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++) if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}} } //--> </script> </head> <body bgcolor="ffffff" link=blue vlink="000066" alink=red onLoad="MM_preloadImages('prev_f2.gif','prev_f3.gif','print_f2.gif','print_f3.gif','up_f2.gif','up_f3.gif','next_f2.gif','next_f3.gif');"> END endfunction function blank() return << END <html> <head> <script language="Javascript"> <!-- function readCookie() { window.resizeTo=(340, 160); var the_cookie = document.cookie; var first=0, last=0; first = the_cookie.indexOf('glossary'); first += 9; last = the_cookie.indexOf(';', first); if(last == -1) last= the_cookie.length; var good= the_cookie.substring(first, last); writestuff(good); } function writestuff(goody) { good_array=goody.split(':'); document.writeln('<font size= "+1">' + good_array[0] + "</font><br>" + good_array[1] + "<br><br><a href='#'>Top</a><br><br>"); } //--> </script> </head> <body> </body> END endfunction function wrongpass() wp<<END <html> <body> Access denied. </body> </html> END write string wp "wrongpass.htm" endfunction