Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

how to resize this window

New Here ,
Aug 20, 2010 Aug 20, 2010

hi below is code when i clicked to open window form.cfm i need to resize to different height and width , i am not sure how to set height and width any help?

function lookup() {
document.location = 'form.cfm';
}


<td align="center">
<input type="button" value="Look" class="p" style="width:250px;"  onClick="lookup();">
</td>


Thanks
TOPICS
Getting started
457
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Aug 30, 2010 Aug 30, 2010

This is rather a JavaScript question. Assuming your form.cfm is a popup, there are number of JavaScript functions to open popup with any size you want (Google keyword : JavaScript popup script).

If you are trying to resize the same browser, you can use JavaScript function window.resizeTo(width,height) like

function lookup() {
window.resizeTo(1024,768);
}

But I don’t think there is a way you can forward the user to another window with specification for that window to resize automatically. only way you can do that is, if you pass your size values in the url as url values and in the form.cfm page, if you write a javascript mix with coldfusion to resize that page, if the url values are passed in.

Thanks

Sam
cflove.org

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Aug 30, 2010 Aug 30, 2010
LATEST

Please try this too

function lookup(file,window)

     childWindow=open(file,window,'resizable=yes,width=825,height=750,scrollbars=yes');
    
}

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources