You've made some modifications to the markup and possibly to the script code as well. In any case, use this version of the script code:
Code:
<script type="text/javascript">
/***********************************************
* Tabbed Document Viewer script- © Dynamic Drive DHTML code library (www.dynamicdrive.com)
* Modified by Raymond Angana rangana in dynamicdrive.com/forums
* First seen in dynamicdrive.com/forums
* Modification - Allow multiple tabbed content viewer
* This notice MUST stay intact for legal use
* Visit Dynamic Drive at http://www.dynamicdrive.com/ for full source code
***********************************************/
var selectedtablink=""
var tcischecked=false
function handlelink(aobject,targFrame){
targFrame = targFrame || 'tabiframe';
selectedtablink=aobject.href
tcischecked= false
if (document.getElementById && !tcischecked){
var tabobj=document.getElementById("tablist")
var tabobjlinks=tabobj.getElementsByTagName("A")
for (i=0; i<tabobjlinks.length; i++)
tabobjlinks[i].className=""
aobject.className="current"
document.getElementById(targFrame).src=selectedtablink
return false
}
else
return true
}
function handleview(e){
if (document.getElementById && e.checked){
if (selectedtablink!="")
window.location=selectedtablink
}
}
</script>
Notes: That fixes the viewer for the code in your post. However, if any of these pages you want to open in the viewer have code on them to "break out of frames", there's nothing you can do about it unless you can remove that code from that/those page(s).
Bookmarks