akulion
09-23-2006, 06:45 PM
1) Script Title: DHTML Window
2) Script URL (on DD):http://dynamicdrive.com/dynamicindex8/dhtmlwindow.htm
3) Describe problem: None, just need an additional function
Hi
In the above mentioned script there is a maxmize / restore function used as follows:
function maximize(){
if (minrestore==0){
minrestore=1 //maximize window
document.getElementById("maxname").setAttribute("src","restore.gif")
document.getElementById("dwindow").style.width=ns6? window.innerWidth-20+"px" : iecompattest().clientWidth+"px"
document.getElementById("dwindow").style.height=ns6? window.innerHeight-20+"px" : iecompattest().clientHeight+"px"
}
else{
minrestore=0 //restore window
document.getElementById("maxname").setAttribute("src","max.gif")
document.getElementById("dwindow").style.width=initialwidth
document.getElementById("dwindow").style.height=initialheight
}
document.getElementById("dwindow").style.left=ns6? window.pageXOffset+"px" : iecompattest().scrollLeft+"px"
document.getElementById("dwindow").style.top=ns6? window.pageYOffset+"px" : iecompattest().scrollTop+"px"
}
I wanted to ask is there a way to have a "minimize / restore" function?
So that only the title bar of the window shows upon minimization?
Any help appretiated,
Thanks,
Aku
2) Script URL (on DD):http://dynamicdrive.com/dynamicindex8/dhtmlwindow.htm
3) Describe problem: None, just need an additional function
Hi
In the above mentioned script there is a maxmize / restore function used as follows:
function maximize(){
if (minrestore==0){
minrestore=1 //maximize window
document.getElementById("maxname").setAttribute("src","restore.gif")
document.getElementById("dwindow").style.width=ns6? window.innerWidth-20+"px" : iecompattest().clientWidth+"px"
document.getElementById("dwindow").style.height=ns6? window.innerHeight-20+"px" : iecompattest().clientHeight+"px"
}
else{
minrestore=0 //restore window
document.getElementById("maxname").setAttribute("src","max.gif")
document.getElementById("dwindow").style.width=initialwidth
document.getElementById("dwindow").style.height=initialheight
}
document.getElementById("dwindow").style.left=ns6? window.pageXOffset+"px" : iecompattest().scrollLeft+"px"
document.getElementById("dwindow").style.top=ns6? window.pageYOffset+"px" : iecompattest().scrollTop+"px"
}
I wanted to ask is there a way to have a "minimize / restore" function?
So that only the title bar of the window shows upon minimization?
Any help appretiated,
Thanks,
Aku