[ Index ]
osCommerce Docs :: PHP Cross Reference For osCommerce 2.2 MS2
Provided By OSCdox.com

/install/templates/main_page/ -> javascript.js (source)

[Summary view]

   1  /*
   2    $Id: javascript.js,v 1.1 2003/07/09 01:11:06 hpdl Exp $
   3  
   4    osCommerce, Open Source E-Commerce Solutions
   5    http://www.oscommerce.com
   6  
   7    Copyright (c) 2003 osCommerce
   8  
   9    Released under the GNU General Public License
  10  */
  11  
  12  function toggleBox(szDivID) {
  13    if (document.layers) { // NN4+
  14      if (document.layers[szDivID].visibility == 'visible') {
  15        document.layers[szDivID].visibility = "hide";
  16        document.layers[szDivID].display = "none";
  17        document.layers[szDivID+"SD"].fontWeight = "normal";
  18      } else {
  19        document.layers[szDivID].visibility = "show";
  20        document.layers[szDivID].display = "inline";
  21        document.layers[szDivID+"SD"].fontWeight = "bold";
  22      }
  23    } else if (document.getElementById) { // gecko(NN6) + IE 5+
  24      var obj = document.getElementById(szDivID);
  25      var objSD = document.getElementById(szDivID+"SD");
  26  
  27      if (obj.style.visibility == 'visible') {
  28        obj.style.visibility = "hidden";
  29        obj.style.display = "none";
  30        objSD.style.fontWeight = "normal";
  31      } else {
  32        obj.style.visibility = "visible";
  33        obj.style.display = "inline";
  34        objSD.style.fontWeight = "bold";
  35      }
  36    } else if (document.all) { // IE 4
  37      if (document.all[szDivID].style.visibility == 'visible') {
  38        document.all[szDivID].style.visibility = "hidden";
  39        document.all[szDivID].style.display = "none";
  40        document.all[szDivID+"SD"].style.fontWeight = "normal";
  41      } else {
  42        document.all[szDivID].style.visibility = "visible";
  43        document.all[szDivID].style.display = "inline";
  44        document.all[szDivID+"SD"].style.fontWeight = "bold";
  45      }
  46    }
  47  }
  48  
  49  function changeStyle(what, how) {
  50    if (document.getElementById) {
  51      document.getElementById(what).style.fontWeight = how;
  52    } else if (document.all) {
  53      document.all[what].style.fontWeight = how;
  54    }
  55  }
  56  
  57  function changeText(where, what) {
  58    if (document.getElementById) {
  59      document.getElementById(where).innerHTML = what;
  60    } else if (document.all) {
  61      document.all[where].innerHTML = what;
  62    }
  63  }


Generated: Tue Nov 4 23:53:39 2003
Hosted By :: AABox.com
Cross-referenced by PHPXref 0.4