|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Form Buttons...
I have a couple of form buttons that as actions go to a different page. I am wondering if anyone knows of a way to have the action load the desired page in a new browser window. Something similar to the target="_new" property for the href
|
|
#2
|
|||
|
|||
|
RE: Form Buttons...
forms can have targets.
or you could have Code:
<button onClick="window.open('whatever','whoever','width=400');">i'm a button</button>
|
|
#3
|
|||
|
|||
|
RE: Form Buttons...
Humm... Cool. Kind of worked. Is there a way to code it so that it loads maximized?
So far I have: <button class="button" onClick="window.open('adminit.php', width=400);">Administrative Items</button> |
|
#4
|
|||
|
|||
|
RE: Form Buttons...
How do I make it NOT open a new window?
|
|
#5
|
|||
|
|||
|
RE: Form Buttons...
just do window.open('adminit.php')
then in the <head> section of adminit.php Code:
<script language="JavaScript1.2">
<!--
top.window.moveTo(0,0);
if (document.all) {
top.window.resizeTo(screen.availWidth,screen.avail Height);
}
else if (document.layers||document.getElementById) {
if (top.window.outerHeight<screen.availHeight||top.window.outerWidth<
screen.availWidth){
top.window.outerHeight = screen.availHeight; top.window.outerWidth = screen.availWidth; }
}
//-->
</script>
|
|
#6
|
|||
|
|||
|
RE: Form Buttons...
NOT in a new window
<input onClick="document.location.href = 'page.php';"> |
|
#7
|
|||
|
|||
|
RE: Form Buttons...
Cool. The load in the same window worked.
But for the load maximized, what if I am calling pages that I cannot modify? |
|
#8
|
|||
|
|||
|
RE: Form Buttons...
Code:
onClick="window.open('page.php','','top=0,left=0,screenY=0, screenX=0,width='+screen.width+',height='+screen.h eight)
i'm pretty sure it's that |
|
#9
|
|||
|
|||
|
RE: Form Buttons...
Cool. That worked. Awesome.
|
|
#10
|
|||
|
|||
|
RE: Form Buttons...
glad i helped
|
|
#11
|
|||
|
|||
|
RE: Form Buttons...
How do I add scrollbars?
|
|
#12
|
|||
|
|||
|
RE: Form Buttons...
window.open('page.php','','top=0,left=0,screenY=0, screenX=0,width='+screen.width+',height='+screen.h eight+',scrollbars=yes')
|
![]() |
| Viewing: Codewalkers Forums > Other Technologies > Client Side Things > Form Buttons... |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|