var acervulus = '<b>Acervulus</b>: Cushionlike mass of hyphae bearing conidiophores and conidia, usually exposed by splitting of host tissue. (pl. acervuli) <img src="graphics/acervul.gif" align="right" width="150" height="109" />';
var aecium = "<b>Aeciospore, Aecium</b>: In a full-cycled rust, aeciospores carry the fungus to the telial host. They are formed in an aecium, usually a cup-shaped structure, sunken in host tissue.  In the bottom are upright hyphae from which aeciospores are produced.  It may be initially covered by a peridium, which can give a blister-like appearance.  The aecium is formed as a result of sexual fusion of cells but not of the nuclei. (pl. aecia) ";
var alternate = "<b>Alternate host</b>: One of the two hosts of a heteroecious rust (heteroecious meaning it requires two unrelated hosts to complete the life cycle).";
var annual = "<b>Annual canker</b>: A canker that develops for one season and is then stopped by host defenses and callused over.";
var apothecium = '<b>Apothecium</b>: The cup- or saucer-like ascoma (ascus-bearing fruiting body) produced by some ascomycetes. (pl. apothecia)<img src="graphics/apo.gif" width="139" height="148" align="right" />';
var appressorium = "<b>Appressorium</b>: A swelling on a fungus germ tube for attachment to host before penetration; found especially in anthracnose fungi and rusts.";
var ascocarp = "<b>Ascocarp or ascoma</b>: Any structure producing asci such as an apothecium or perithecium.";
var ascomycetes = "<b>Ascomycetes or Ascomycota</b>: Fungi bearing sexual spores in asci.";
var ascus = '<img src="graphics/ascus.gif" width="68" height="400" align="right" /><b>Ascus, ascospores</b>: A microscopic sac containing the sexual spores of ascomycetes.  Usually the sac is elongated, contains 8 ascospores produced by free cell formation, and has a mechanism at the top through which the spores are forcibly ejected. (pl. asci)';
var aseptate = "<b>Aseptate</b>: Without cross-walls.";
var asexual = "<b>Asexual</b>: Characterized by the absence of sexual reproduction and sexual structures.  Asexual reproductive structures (also known as the anamorph or imperfect stage of a fungus) usually result in progeny genetically identical to the parent.";
var bacteria = "<b>Bacteria</b>: Microscopic, prokaryotic, one-celled organisms increasing by fission.";
var basidiocarp = "<b>Basidiocarp or Basidioma</b>: Fruiting body of basidiomycetes, such as mushroom or conk. (pl. basidiomata - you've got to love Latin!!";
var basidium = "<b>Basidium, Basidiospore</b>: The basidium is a cell on which the sexual spores (basidiospores) of basidiomycetes are produced.  Usually it is club-shaped, there are four basidiospores on pegs called sterigmata (sing. sterigma), and the spores are forcibly popped off a short distance.  In some groups (informally called gasteromycetes), the spores do not pop off. (pl. basidia)";
var biotroph = '<b>Biotroph</b>: Parasite that grows and feeds in living host tissues.  Essentially all are obligate parasites.  Most biotrophs produce haustoria, special fungal cells that penetrate host cell walls (not membranes) and absorb nutrients. <img width="194" height="102" src="graphics/haustori.gif" />';
var blight = "<b>Blight</b>: A disease with sudden, severe leaf damage and often with general killing of flowers and shoots.";
var bracts = "<b>Bracts</b>: A modified, usually reduced leaflike structure.";
var broom = "<b>Witches' broom</b>: Abnormal brushlike development of many weak branches.";
var brown = "<b>Brown rot</b>: Decay characterized by degradation of cellulose and hemicellulose, but practically no lignin.  The wood usually becomes brown and loses fibrous structure. ";
var callus = "<b>Callus</b>: Undifferentiated tissue; a term used in tissue culture, grafting, and tree healing.  In the latter case, callus is produced by cambium around wounds and becomes bark which slowly grows over the wound.";
var cambium = "<b>Cambium</b>: A meristem that gives rise to sheets or planes of cells.  When no qualification is given, it usually refers to the vascular cambium, between the inner bark and wood, which gives rise to both phloem (inner bark) to the outside and wood to the inside.  There is also a cork cambium, or phellogen.";
var canker = "<b>Canker</b>: A lesion on the bark of a stem or shoot, usually with a sharply delimited necrosis of the cortical tissue.";
var cavity = "<b>Wildlife or Cavity tree</b>: Live or dead tree containing an excavation (usually in decayed heartwood) for nesting, denning or shelter of animals.";
var cellulose = "<b>Cellulose</b>: The chief component of the cell wall in plants and some protists; an insoluble complex carbohydrate formed of microfibrils of glucose molecules attached end to end.";
var chitin = "<b>Chitin</b>: A tough, resistant, nitrogen-containing polysaccharide; component of cell walls of certain fungi.";
var chlamydospore = "<b>Chlamydospore</b>: Thick-walled, asexual resting spore formed by the rounding up of any hyphal cell; also used for smut spores.";
var chlorosis = "<b>Chlorosis</b>: Yellowing of normally green tissue.   May be general, as from root disease or nutrient deficiency, or localized, from a foliage disease.  Adjective: chlorotic.";
var clamp = '<b>Clamp connection</b>: Short hyphal branch that fuses with the parent hypha just behind branch origin. The branch contains a septum (crosswall), as does the parent hypha just below the branch.  Clamps are found only in basidiomycetes, only in the dikaryon stage, but not all basidiomycetes form them.<img src="graphics/clamp.gif" width="250" height="75" />';
var cleistothecium = "<b>Cleistothecium</b>: An enclosed ascoma without a special opening; sometimes restricted to those with asci scattered in no particular layer but loosely applied to powdery mildews. (pl. cleistothecia)";
var columella = "<b>Columella</b>: Sterile central axis in a mature fruiting body.";
var conidiophore = "<b>Conidiophore</b>: Simple or branched specialized hypha on which conidia are produced.";
var conidium = "<b>Conidium</b>: Any asexual spore except sporangiospore or chlamydospore; produced externally on conidiogenous cells (pl. conidia).  In some cases they are produced inside a fruiting structure called a <b>conidioma</b> (plural conidiomata)";
var conk = "<b>Conk</b>: Term used in forestry for basidiomata of polypores on trees.";
var coremium = "<b>Coremium</b>: Synnema, a cluster of erect hyphae bearing conidia. (pl. coremia)";
var cotyledon = "<b>Cotyledon</b>: Embryonic leaf of a seed or seedling; generally stores food in dicotyledons and absorbs food in momocotyledons.";
var cuticle = "<b>Cuticle and Cutin</b>: Waxy or fatty layer on outer wall of epidermal cells, formed of wax and cutin.";
var cytoplasm = "<b>Cytoplasm</b>: The living matter of a cell, exclusive of the nucleus; the protoplasm.";
var damping = "<b>Damping off</b>: Seed decay in soil, or seedling blight initiated at or below the soil line.  May occur before or after seedling emergence above soil.";
var decline = "<b>Decline</b>: A type of disease of complex cause occurring in mature cohorts of trees.  Often, but incorrectly, the term is used when the cause of the disease is unknown.";
var decomposer = "<b>Decomposer</b>: Organism (bacteria, fungi, heterotrophic protists) that breaks down organic material into smaller molecules.";
var diagnostic = "<b>Diagnostic</b>: Leading directly to diagnosis.  Said of symptoms and/or signs that lead to a conclusive diagnosis of a specific disease.";
var dieback = "<b>Dieback</b>: Progressive death of branches or shoots beginning at tips.  It is a symptom, but it is sometimes used improperly to refer to a decline disease.";
var diffuse = "<b>Diffuse cankers</b>: Cankers in which the necrosis spreads rapidly and the host can not build up barriers and callus to stop it.";
var dikaryotic = "<b>Dikaryotic</b>: In fungi, having pairs of nuclei within cells or compartments.  Such a mycelium can be called a dikaryon";
var diploid = "<b>Diploid</b>: Having two sets of chromosomes (2n); diploidy is characteristic of the sporophyte generation.";
var disease = '<b>Disease</b>: Any deviation in the normal functioning of a plant caused by some type of persistent agent or environmental condition. See <a href="concepts.html">detailed discussion</a>';
var dissemination = "<b>Dissemination</b>: Transport of inoculum from a diseased to a healthy plant.";
var epidemiology = "<b>Epidemiology</b>: The study of disease in populations.  Includes patterns of and factors controlling change in amount of disease in a population of plants.";
var epidermis = "<b>Epidermis</b>: The outermost layer of cells of the leaf and of young stems and roots; primary in origin.";
var etiology = "<b>Etiology</b>: Study of the cause of disease.";
var eukaryotic = "<b>Eukaryotic</b>: A cell that has a membrane-bound nucleus, membrane-bound organelles, and chromosomes in which the DNA is associated with proteins; an organism composed of such cells.";
var fertilization = "<b>Fertilization</b>: The bringing together in a common body of two gamete nuclei and ultimately their fusion to form a diploid zygote.";
var flagellum = "<b>Flagellum</b>: A long threadlike organelle that protrudes from the surface of a cell and is usually involved in motility. (pl. flagella)";
var flagging = "<b>Flagging</b>: Occurrence of dying or recently dead branches, the foliage color of which contrasts with healthy foliage. ";
var fruiting = "<b>Fruiting body</b>: Fungus structure containing or bearing spores; e.g., mushroom, pycnidium, perithecium, apothecium.";
var fungus = "<b>Fungus (pl. fungi)</b>: Fungi are eukaryotic.  The basic structural unit is usually a hypha with a rigid cell wall containing chitin and with indeterminate growth.  Fungi feed by breaking down and absorbing organic matter produced by others (absorptive heterotrophy) and reproduce by sexual or asexual spores.";
var fusiform = "<b>Fusiform</b>: Spindle-like, narrowing at the ends.";
var gall = "<b>Gall</b>: Outgrowth or swelling, often more or less spherical, of unorganized plant cells as result of attack by bacteria, fungi, or other organisms.";
var gametangium = "<b>Gametangium</b>: Structure producing gametes, the fertilizing elements of sex.";
var germ = "<b>Germ tube</b>: Hypha produced by a germinating fungus spore.";
var germination = "<b>Germination</b>: The beginning or resumption of growth by a spore, seed, bud, or other structure.";
var glucose = "<b>Glucose</b>: A common six-carbon sugar (C<sub>6</sub>H<sub>12</sub>O<sub>6</sub>); the most common monosaccharide in most organisms.";
var graft = "<b>Graft</b>: A union of different individuals.  In horticulture, a portion, called scion, of one individual is inserted into a root or stem, called the stock, of the other individual.";
var hardwood = '<b>Hardwood</b>: Tree in the division of flowering plants; angiosperms.  Usually, but not always, their wood is harder and fibers shorter than the tracheids of conifers ("softwoods"), and wood contains relatively large, water-conducting vessels. See <a href="wood.html#">the Wood page</a> for further details.';
var haustorium = '<b>Haustorium</b>: Parasitic organ that penetrates host tissues (e.g., mistletoes) or cells (fungi such as powdery mildews and rusts).  Fungal haustoria (figure) penetrate host cell walls (not membranes) and are usually branched, which increases surface area and opportunity for exchange of materials. <img width="194" height="102"  src="graphics/haustori.gif" />';
var heartwood = "<b>Heartwood</b>: Nonliving, inner and often dark-colored wood in which no water transport occurs; it is surrounded by sapwood.  Has preformed defenses but no active defenses.";
var hemicellulose = "<b>Hemicellulose</b>: A polysaccharide of various sugars, more soluble and less ordered than cellulose; found particularly in cell walls.";
var heterothallic = "Requiring individuals of differing mating type for sexual reproduction.";
var heterotrophic = "<b>Heterotrophic</b>: Using organic mater produced by another organism for nutrition.";
var host = "<b>Host</b>: Organism from which a parasite derives nutrition.";
var hymenium = "<b>Hymenium</b>: Spore-bearing layer of a fungus fruiting body.";
var hypha = "<b>Hypha</b>: The basic form of fungal structure, consisting of a cylindrical, branched filament.  It has a cell wall on the outside, then a membrane and cell contents on the inside.  Crosswalls usually break the hypha into compartments or cells. (pl. hyphae)";
var infection = "<b>Infection court</b>: Place where an infection may take place, as wound, stomate, fruit, petal, etc.";
var inoculum = "<b>Inoculum</b>: Pathogen or its part, as spores, fragments of mycelium, etc. that can infect plants.";
var karyogamy = "<b>Karyogamy</b>: Fusion of nuclei as part of the sexual cycle, usually going from haploid to diploid.";
var koch = "<b>Koch's postulates</b>: A protocol for proving pathogenicity of a suspected pathogen.  For culturable organisms, it includes:<br />1. Observe consistent association of pathogen with disease.<br />2. Isolate pathogen from diseased tissue.<br />3. Inoculate pathogen into healthy host and reproduce symptoms.<br />4. Reisolate pathogen from inoculated host.";
var laminated = "<b>Laminated</b>: Separating into sheets or layers.  In wood decay separation may be along annual rings. ";
var lichen = "<b>Lichen</b>: Symbiotic relationship between a fungus and an alga.";
var lignin = "<b>Lignin</b>: One of the most important constituents of the secondary wall of vascular plants, although not all secondary walls contain lignin; after cellulose, lignin is the most abundant plant polymer.";
var macroscopic = "<b>Macroscopic</b>: Large enough to be seen with the naked eye.";
var meiosis = "<b>Meiosis</b>: Reduction division, going from one diploid nucleus to four haploid nuclei.  Sexual recombination usually takes place during meiosis.";
var mesophyll = "<b>Mesophyll cells</b>: The ground tissue (parenchyma) of a leaf, located between the layers of epidermis; mesophyll cells generally contain chloroplasts.";
var micron = "<b>Micron</b>: 1/1000 millimeter, unit used for measuring spores.";
var middle = "<b>Middle lamella</b>: The layer of intercellular material, rich in pectin compounds, cementing together the primary walls of adjacent cells.";
var mitosis = "<b>Mitosis</b>: Division of a nucleus, duplicating chromosomes, usually creating identical daughter nuclei.  Usually accompanied by cell division.";
var mutualistic = "<b>Mutualistic symbiosis</b>: Living together of two or more organisms in an association that is mutually advantageous.";
var mycelium = "<b>Mycelium</b>: Mass of fungus hyphae; branching filamentous strands. (pl. mycelia)";
var mycorrhiza = "<b>Mycorrhiza (pl. mycorrhizae)</b>: Symbiotic, nonpathogenic association of fungi and roots.  There are two basic types: <dt>Arbuscular (endo-) mycorrhizae</dt> <dd>Characterized by intercellular hyphae and occasional penetration of cell walls to form arbuscules that invaginate the host membrane.  Mycobionts are in the Glomeromycota.</dd> <dt>Ectomycorrhizae</dt> <dd>Characterized by a fungal mantle outside the root and a fungal Hartig net between the cortical cells.  No penetration of plant cells by the fungus.  Mycobionts include mostly various members of Agaricomycetes in the Basidiomycota, the Pezizomycetes and a few other members of the Ascomycota, and <i>Endogone</i> in the Zygomycota.</dd>";
var necrosis = "<b>Necrosis</b>: Dying of any tissues.  Usually obvious because of darkening, shrivelling.  Adjective: necrotic.";
var necrotroph = "<b>Necrotroph</b>: A parasite that kills host tissue as it progresses, then feeds on the dead tissue.  Most would be considered facultative parasites (has the ability to parasitize a living host, but can also survive and grow as a saprobe in dead material).";
var nematode = "<b>Nematode</b>: Roundworms, eelworms, cause of some plant disease.";
var nucleic = "<b>Nucleic acid</b>: An organic acid consisting of joined nucleotide complexes; the two types are deoxyribonucleic acid (DNA) and ribonucleic acid (RNA).";
var oogonium = "<b>Oogonium and antheridium</b>: Female and male sex organs, respectively, in the Oomycota.  Fertilization results in a resting spore called an oospore.";
var overwintering = "<b>Overwintering</b>: Means of surviving through winter.  For instance, a fungus may remain dormant in the host tissue over the winter.";
var parasitism = "<b>Parasitism</b>: Living on or in another living organism, from which nutrition is derived.  A parasite usually, but not necessarily, causes disease.<ul><li>Obligate parasite: requires living host for normal development in nature.</li>	<li>Facultative parasite: has the ability (faculty) to parasitize a living host, but can also survive and grow as a saprobe in dead material.</li></ul>";
var parenchyma = "<b>Parenchyma cells</b>: Living, generally thin-walled cell of variable size and form; mostly undifferentiated; the most abundant kind of cell in plants.";
var pathogen = '<b>Pathogen</b>: Agent that causes disease ("path"-"gen").  See <a href="concepts.html#pathogens">detailed discussion</a>';
var perennial = "<b>Perennial</b>: Persisting and growing for multiple years.  The term is often used for cankers when killing by the pathogen is roughly balanced by growth of the host, so the canker persists for many years.";
var perithecium = "<b>Perithecium</b>: Subglobose or flasklike ascoma with an opening at the top and an organized layer of asci, in which ascospores are produced.  (pl. perithecia)";
var phloem = "<b>Phloem</b>: The food-conducting tissue of vascular plants, which is composed of sieve elements, various kinds of parenchyma cells, fibers, and sclereids.  In trees it is the inner bark.";
var plasmogamy = "<b>Plasmogamy</b>: Union of the protoplasts of gametes that is not immediately accompanied by union of their nuclei.";
var plasma = "<b>Plasma membrane</b>: Outer boundary of the protoplast, next to the cell wall; consists of a single membrane; also called cell membrane, and ectoplast.";
var pleomorphic = "<b>Pleomorphic</b>: Capable of changing shape.";
var polymerization = "<b>Polymerization</b>: The chemical union of monomers such as glucose or nucleotides to form polymers such as starch or nucleic acid.";
var popup = "<b>Popup</b>: A box with a definition that pops up, like a tooltip, to define words indicated in blue.  If you keep still or move into the popup it will stay; mouse out otherwise and it will fade.";
var prokaryotic = "<b>Prokaryotic</b>: Lacking a true nucleus and membrane-bound organelles; includes bacteria and phytoplasma.";
var pseudothecium = "<b>Pseudothecium</b>: A fruiting body containing double-walled (bitunicate) asci, formed by hollowing out of a stroma, usually with a pore at the tip.";
var punk = "<b>Punk knot</b>: Decayed branch stub that may be sunken or swollen, resinous and festered, indicating decay inside the stem.  The term is usually used in cases where fungal mycelium partly replaces the embedded branch, especially with <i>Phellinus pini</i>.";
var pycnidium = "<b>Pycnidium</b>: Flasklike fruiting body containing conidia. (pl. pycnidia)";
var radicle = "<b>Radicle</b>: The embryonic root and first root of a germinating seed.";
var resinosis = "<b>Resinosis</b>: Abnormal exudation of resin or pitch from conifers.";
var resupinate = "<b>Resupinate</b>: Flattened on the substrate, used for conks that do not have a projecting cap (pileus).";
var rhizomorph = "<b>Rhizomorph</b>: Rootlike structure produced by fungi.  In the strict sense, it has differentiated tissues and has an organized apical meristem and branches.";
var rust = "<b>Rust</b>: A fungus in the order Uredinales or the disease it causes.  Rust fungi are highly specialized, obligate parasites of higher plants and often have complex life cycles involving two unrelated hosts.";
var saprobe = "<b>Saprobe</b>: An organism that secures its food directly from nonliving organic matter.";
var saprot = "<b>Sap rot</b>: Decay of dead wood by saprobic organisms; some fungi can decay sapwood in living trees.";
var sapwood = "<b>Sapwood</b>: Outer part of the wood (xylem), usually distinguished from the heartwood by its lighter color, in which parenchyma are alive and active conduction of water takes place.";
var sclerotium = "<b>Sclerotium</b>: a resting structure and propagule of a fungus composed of many thick-walled somatic cells and usually having a dark, melanized rind (pl. sclerotia)";
var septate = "<b>Septate</b>: Having crosswalls.";
var septum = "<b>Septum</b>: Crosswall in a fungal hypha. (pl. septa)";
var sexual = "<b>Sexual reproduction</b>: Alternation of chromosome number accompanied by recombination and reshuffling.  The diploid number becomes haploid via meiosis, during which chromosomes may recombine.  The diploid number is regained by fusion of gametic nuclei (karyogamy).";
var sign = '<b>Sign</b>: Macroscopically visible <em>pathogen</em> tissues associated with disease. Examples:<ul><li> Heart rot by <i>Phellinus igniarius</i>: conk<li>Armillaria root rot: mushroom, rhizomorph, mycelial fan<li>Laminated root rot: conk of <i>Phellinus sulphurascens</i>, setal hyphae</ul>  See <a href="concepts.html#signs">signs and symptoms</a>';
var smut = "<b>Smut</b>: A fungus of the Ustilaginales, characterized by sooty spore masses; the name also used for the disease caused by the smut.";
var softwood = "<b>Softwood</b>: A conifer; tree in the Coniferales.  The wood is usually softer than that of hardwoods.  It contains relatively long tracheids that provide strength and water conduction.";
var spermogonium = "<b>Spermogonium</b>: Fruiting structure in which spermatia are produced, referred to as pycnium in some (particularly older) rust literature.";
var spermatium = "<b>Spermatium</b>: In some ascomyetes and rusts, a small gamete which may be transferred to accomplish sexual fertilization.  Spermatia resemble small spores but cannot germinate to form somatic hyphae.";
var sporangium = "<b>Sporangium, Sporangiophore</b>: Sporangia are cells inside which spores are produced.  The term is usually used for asexual structures such as in the Zygomycota and Oomycota.  In the Zygomycota the sporangium is often borne on an erect hyphal branch, the sporangiophore.  In the Oomycota the sporangia typically carry swimming spores with flagella. (zoospores)";
var spore = "<b>Spore</b>: A single- to many-celled reproductive body in the fungi.  It is usually dispersed or designed for surviving dormant periods or both.";
var sporodochium = "<b>Sporodochium</b>: Cluster of conidiophores on an interwoven stroma or mass of hyphae. (pl. sporodochia)";
var sporulation = "<b>Sporulation</b>: Production of spores.";
var stemdecay = "<b>Stem decay</b>: Decay in stems of living trees, focused in the inner wood.  The term heart rot is somewhat discouraged because it may be wrongly interpreted as decay restricted to heartwood and because it is somewhat ambiguous as to location.";
var stroma = "<b>Stroma</b>: Mass of fungus hyphae often including host tissue containing or bearing spores. (pl. stromata)";
var symptom = '<b>Symptom</b>: Change in appearance of <em>host</em> tissues in response to disease.  Examples:<ul><li> Root rots: crown thinning, dieback, resinosis, decay, etc.  <li> Foliage diseases: discolorations, lesions, defoliation</ul>  See <a href="concepts.html#signs">signs and symptoms</a>';
var systemic = "<b>Systemic</b>: Infecting an entire host or large portion thereof, not localized.  Also can be used for fungicides that are transported inside a plant.";
var target = "<b>target (perennial) canker</b>: A canker that persists for multiple years.  The host produces a layer of callus that is killed each dormant season, leaving a series of concentric rings (target).";
var teleomorph = "<b>Teleomorph</b>: The sexually reproductive stage of a fungus, also known as the perfect stage.";
var telium = "<b>Teliospore, Telium</b>: Spore from which basidium is produced by rust fungi.  Teliospores are produced on a telium.";
var uredinium = "<b>Urediniospore, Uredinium</b>: In rust fungi, a reddish, usually spiny, binucleate spore produced in summer; it reinfects the same host species.  Urediniospores are produced in a uredinium.";
var vector = "<b>Vector</b>: A motile organism, often an insect, that carries inoculum of a pathogen to a new host, dispersing and often introducing it.";
var virulence = "<b>Virulence</b>: Variously defined, but often refers to the relative capacity of a pathogen to cause disease.";
var virus = "<b>Virus</b>: An acellular, obligate parasite, sub-microscopic, recognizable by the effects produced in infected hosts.  Has nucleic acid and protein coat.";
var white = "<b>White rot</b>: Decay characterized by degradation of all wood components: cellulose, hemicellulose, and lignin.  The wood is usually normal color or bleached and retains some fibrous structure.";
var xylem = "<b>Xylem</b>: A complex of vascular tissue through which most of the water and minerals of a plant are conducted; characterized by the presence of tracheary elements.";
var zone = "<b>Zone line</b>: Dark line in wood, associated with fungal decay and usually formed of melanized, thick-walled fungal cells.";
var zoosporangium = "<b>Zoosporangium, Zoospore</b>: A sporangium bearing zoospores, which can swim using flagella.";
var zygospore = "<b>Zygospore</b>: Resting spore formed from the union of similar gametes.";

// This code is scrounged from various sources, but the difficult cross-browser
// positioning problems (detecting event location, browser window size, and setting 
// the position for the definition box) were solved with object detection code from 
// http://www.howtocreate.co.uk

var compliant = (document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) ? true : false ;
var iDelay = 250 ;		 // Delay before fading in milliseconds
var sTipTimer = null ;	// sTipTimer is the name/ID of the tip timeout timer.
var id = "tipID" ;			// tipID is the id of the tip object
var fadeCounter = 0;  		// Frame counter for the fades.
var colorValue = 250;		// Color value for the fades.
var oTip = null ; 		// oTip is a reference to the actual tip object (as opposed to the id of the object)
oTip = document.getElementById ? document.getElementById(id) : document.all[id] ;
var mouseX;   // distance of mouse from left side of DOCUMENT
var mouseY;   // distance of mouse from top of DOCUMENT

function startTip(evt,def) {
	// Location of mouse relative to document origin; 
	// have to get this here cause of bug in ie5.2 mac.  Does anyone still use that?!

	if ( typeof ( evt.pageX ) == 'number' ) { //NS 4, NS 6+, Mozilla 0.9+ 
		mouseX = evt.pageX ;
		mouseY = evt.pageY ; } 
	else {
		if ( typeof( evt.clientX ) == 'number' ) { //IE, Opera, NS 6+, Mozilla 0.9+
			//except that NS 6+ and Mozilla 0.9+ did pageX ... 
			mouseX = evt.clientX ; 
			mouseY = evt.clientY ; 
			if ( !( ( window.navigator.userAgent.indexOf( 'Opera' ) + 1 ) || ( window.ScriptEngine && ScriptEngine().indexOf( 'InScript' ) + 1 ) || window.navigator.vendor == 'KDE' ) ) { 
				if( document.body && ( document.body.scrollLeft || document.body.scrollTop ) ) { 
					//IE 4, 5 & 6 (in non-standards compliant mode) 
					mouseX += document.body.scrollLeft;
					mouseY += document.body.scrollTop; 
				} 
				else if( document.documentElement && ( document.documentElement.scrollLeft || document.documentElement.scrollTop ) ) { 
					//IE 6 (in standards compliant mode) 
					mouseX += document.documentElement.scrollLeft;
					mouseY += document.documentElement.scrollTop;
				}
			}
		} 
	}

	writeTip(def) ;
	clearTimeout(sTipTimer) ;
	position(evt) ;
	oTip.style.visibility = "visible" ;
	fadein() ;
}

function writeTip(def) {
	oTip.innerHTML =  "" ;	 // If I don't do this, box gets extra space in it, but why?
	oTip.innerHTML = def ; }

function position() {

	if( typeof( window.innerWidth ) == 'number' ) {		//Non-IE
		winW = window.innerWidth -20 ;
		winH = window.innerHeight - 20 ;
		scrollX = window.pageXOffset ;
		scrollY = window.pageYOffset ; 
		}
	else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) { //IE 6+ in 'standards compliant mode'
		winW = document.documentElement.clientWidth ;
		winH = document.documentElement.clientHeight ; 
		scrollX = document.documentElement.scrollLeft ;
		scrollY = document.documentElement.scrollTop ; 
		}
	else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) { //IE 4 compatible
		winW = document.body.clientWidth ;
		winH = document.body.clientHeight ; 
		scrollX = document.body.scrollLeft ;
		scrollY = document.body.scrollTop ; 
		}

	winRight = scrollX + winW ;	 // right edge of browser window relative to document
	winBottom = scrollY + winH ; 	// bottom of browser window relative to document
	tipWidth = oTip.offsetWidth ;		// width of the tip box
	tipHeight = oTip.offsetHeight ;		// height of the tip box
	
	// Vertical placement first. 10px below mouse if it will fit.  Otherwise 10px above window bottom.
	if (mouseY < ( winBottom - tipHeight - 10 ) )
		oTip.style.top = mouseY + 10 + "px" ; 
	else oTip.style.top = winBottom - tipHeight - 10 + "px" ;
	// Horizontal placement. 10px right of mouse if it will fit. Otherwise 10px left of right window edge.
	if ( mouseX < ( winRight - tipWidth - 20 ) )
    		oTip.style.left = mouseX + 10  + "px" ;
	else 
		oTip.style.left = winRight - tipWidth - 10 + "px"  ;
}

function startTimer(el) {
    clearTimeout(sTipTimer) ;
    sTipTimer = setTimeout("fadeout()",iDelay) ;
}

	////////////////////////////////////////////////////////////////////////////////
	// Fading code based on that of Marcio Galli for Netscape Communications.
	// References:
	// http://www.mozilla.org/docs/dom/samples/dom-css-fonts/fadespacing.html
	// http://www.mozilla.org/docs/dom/technote/tn-dom-table/index.html
	// http://dmoz.org/Computers/Programming/Languages/JavaScript/W3C_DOM/
	// http://www.geckonnection.com
	///////////////////////////////////////////////////////////////////////////////////////

function fadein() {
		// 20-step animation procedure starting at fadeCounter=0, colorvalue 250. 
	if (fadeCounter<20) {
			fadeCounter++;

			// Decreases the colorValue by 15, then 10 for the second half.
			if (fadeCounter<11) colorValue -= 8 ;
			else colorValue -= 17 ;

			// Sets the color for the id element. 
			oTip.style.color="rgb("+colorValue+","+colorValue+","+colorValue+")";
			oTip.style.borderColor="rgb("+colorValue+","+colorValue+",255)";
			oTip.style.backgroundColor="rgb("+colorValue+",255,255)";
			
			// Call fadein again after x number of milliseconds. 
			setTimeout("fadein()",20);
	} else {
			// After the 20 steps, reset values. 
			fadeCounter = 0 ;
			colorValue = 0 ;
	}
}

function fadeout() {
		// 16-step animation procedure starting at fadeCounter=0. 
	if (fadeCounter<16) {
		fadeCounter++;

		// Increases the colorValue by 24, then 8 for the second half.
		if (fadeCounter<9) colorValue+=24 ;
		else colorValue+=8;

		// Sets the color for the id element. 
		oTip.style.color="rgb("+colorValue+","+colorValue+","+colorValue+")";	
		oTip.style.borderColor="rgb("+colorValue+","+colorValue+",255)";
		oTip.style.backgroundColor="rgb("+colorValue+",255,255)";

		// Call fadeout again after x number of milliseconds. 
		setTimeout("fadeout()",15);
	} else {
		// After the 16 steps, reset values and hide the element all the way
		fadeCounter = 0 ;               
		colorValue = 250 ;
		oTip.style.visibility="hidden"
	}
}