topical media & game development

talk show tell print

graphic-javascript-effect-image-gallery.js / js



  /* This script and many more are available free online at
  The JavaScript Source!! http://javascript.internet.com
  Created by: Jeremy Keith / Anonymous | http://www.alistapart.com/articles/imagegallery/ */
  function showPic(whichpic) {
    if (document.getElementById) {
      document.getElementById('placeholder').src = whichpic.href;
      if (whichpic.title) {
        document.getElementById('desc').childNodes[0].nodeValue = whichpic.title;
      } else {
        document.getElementById('desc').childNodes[0].nodeValue = whichpic.childNodes[0].nodeValue;
      }
      return false;
    } else {
    return true;
    }
  }
  
  var previousToggle=null;
  function toggleMe(a){
    var e=document.getElementById(a);
    if(!e)return true;
    if(e.style.display=="none"){
      e.style.display="block";
      if(previousToggle)previousToggle.style.display="none";
      previousToggle=e;
    }
    return true;
  }
  
  


(C) Æliens 20/2/2008

You may not copy or print any of this material without explicit permission of the author or the publisher. In case of other copyright issues, contact the author.