Hi i would like an addition to this script as the link of the page i am attaching to it is having more longer height so i should be scrolled, but i don't know how to add scrolling option to this code window.onload = function() { // check to see that the browser supports the getElementsByTagName method // if not, exit the loop if (!document.getElementsByTagName) { return false; } // create an array of objects of each link in the document var popuplinks = document.getElementsByTagName("a"); // loop through each of these links (anchor tags) for (var i=0; i < popuplinks.length; i++) { // if the link has a class of "popup"... if (popuplinks[i].getAttribute("class") == "popup") { // add an onclick event on the fly to pass the href attribute // of the link to our second function, openPopUp popuplinks[i].onclick = function() { openPopUp(this.getAttribute("href")); return false; } } } } function openPopUp(linkURL) { window.open(linkURL,'popup','width=400,height=200') } Code (markup): this is the link to the post where i found this code http://www.openhosti...es/webdev/5918/ thank you in advance
Add scrollbars=1 to the window parameters function openPopUp(linkURL) { window.open(linkURL,'popup','width=400,height=200,scrollbars=1') } Code (markup): Check out this page if you want to do anything else to the window.