HyperLink control in JavaScript : HyperLink : Ajax Layer JAVASCRIPT DHTML TUTORIALS


JAVASCRIPT DHTML TUTORIALS » Ajax Layer » HyperLink »

 

HyperLink control in JavaScript




http://dynapi.sourceforge.net/
GNU LESSER GENERAL PUBLIC LICENSE
Version 2.1, February 1999
<html>
<head>
<title>DynAPI Examples - HTML HyperLink</title>
<script language="JavaScript" src="./dynapisrc/dynapi.js"></script>
<script language="Javascript">
dynapi.library.setPath('./dynapisrc/');
dynapi.library.include('dynapi.api');
dynapi.library.include('TemplateManager');
dynapi.library.include('HTMLHyperLink');
dynapi.library.include('FlashSound');
</script>
<script language="Javascript">

fs = new FlashSound();
fs.setSWF("images/sndfx.swf");
HTMLComponent.setFlashSound(fs)// Set FlashSound object for all HCs

var tp = new Template('This is the Template:<center><table border="1"><tr><td>{@fld}</td></tr></table></center>',100,100,250,200,'lime');
hl = new HTMLHyperLink(null,'Click Here',null,'HTML Hyper Link Demo');
hl.sndOnMouseover = '/click@start';
hl.sndOnClick = '/check@start';
hl.startFlash()
hl.addEventListener({
  onclick:function(e){
    var o=e.getSource();
    o.setURL('dynapi.sf.net'); // jump to url;
    status = 'Visit DynAPI's website at http://'+o.getURL();
    // o.allowEvent(); // By default HyperLink events are canceled (return false)
  }
});

tp.addChild(hl,'fld');
dynapi.document.addChild(tp);

</script>
</head>
<body>
<script>
  dynapi.document.insertAllChildren();
</script>
</body>
</html>

           
       

Download : Download nav_dynapi.zip nav_dynapi.zip


-

Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .

Follow Navioo On Twitter

JAVASCRIPT DHTML TUTORIALS

 Navioo Ajax Layer
» HyperLink