CFWINDOW wont center

Cna someone please go to this link, click on an appointment and tell me why the CFwindow wont center?

Thanks

Judson
LVL 3
judsonmusicAsked:
Who is Participating?
 
SidFishesConnect With a Mentor Commented:
I'm still on 8 here but looks like cfwindow implementation in cf9 -does- cfsuck :)

http://www.coldfusionjedi.com/index.cfm/2009/10/27/Broken-cfwindows

Try Ray's fix and you might check adobe for any patches updates to cf9
0
 
Brijesh ChauhanStaff IT EngineerCommented:
link is missing ? can you post it again..
0
 
judsonmusicAuthor Commented:
0
Cloud Class® Course: Amazon Web Services - Basic

Are you thinking about creating an Amazon Web Services account for your business? Not sure where to start? In this course you’ll get an overview of the history of AWS and take a tour of their user interface.

 
judsonmusicAuthor Commented:
0
 
SidFishesCommented:
centers beautifully on a 1920x1080 screen :) How are you calling the window?

are you using ColdFusion.Window.create ?

some code will be required
0
 
Brijesh ChauhanStaff IT EngineerCommented:
Does not center for me .. same resolution ... 1920 X 1080
Untitled.jpg
0
 
SidFishesCommented:
that's interesting - it centers for a blank appointment (since I was answering the other question that's what I had seen) however it does not center for an existing. The centering does not "stick" with browser resize thoough. I see the same thing as brij for existing

I do get an error in the window however File not found: /scheduler/AJAXtest.cfm

0
 
judsonmusicAuthor Commented:
I have postted this page for testing...

http://www.servicemysite.com/scheduler/AJAXtest.cfm

this is as clean as it gets and it does not center???

Why??? This is very strange.

ALSO CLICK THE 2nd one. WHEN I TAKE THE URL OUT, IT WORKS...
0
 
judsonmusicAuthor Commented:
OK, I figured out a work around

http://www.servicemysite.com/scheduler/AJAXtest.cfm

I first create the window, then load the content into it.

but does anyone know why this is happening?
0
 
judsonmusicAuthor Commented:
CFWINDOW's CFSUCK! lol
0
 
SidFishesCommented:
it only sucks if you provide us code and we can't figure out what is going on :p
0
 
judsonmusicAuthor Commented:
were you not able to rightclick and view source?
0
 
SidFishesCommented:
view source for any of the cfajax tags isn't helpful as it shows the js output created by CF and -not- the cf code that is used to create the widget which is what controls how it looks and acts.
0
 
judsonmusicAuthor Commented:
here ya go buddy. sorry about that.
<cfajaximport tags="cfwindow">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>Untitled Document</title>
</head>
<body>
This window will not center with a url in it.
<cfform name="test">
    <cfinput type="button" name="x" value="Create Window" 
        onClick="ColdFusion.Window.create('Window1', 'This is a CF window',
        'blankPage.cfm',
        {height:300,width:400,modal:true,closable:false,
        draggable:false,resizable:false,center:true,initshow:true, closable:true})">
</cfform>
<br /><br /><br /><br />


This one centers without a url in it. Why?
<cfform name="test">
    <cfinput type="button" name="x" value="Create Window 2" 
        onClick="ColdFusion.Window.create('Window2', 'This is a CF window2',
        '',
        {height:300,width:400,modal:true,closable:false,
        draggable:false,resizable:false,center:true,initshow:true, closable:true})"
        >
</cfform>
<br /><br /><br /><br />

This is the fix. Create the window first, the load the contents.
<cfform name="test">
    <cfinput type="button" name="x" value="Create Window 3" 
        onClick="ColdFusion.Window.create('Window3', 'This is a CF window3',
        '',
        {height:300,width:400,modal:true,closable:false,
        draggable:false,resizable:false,center:true,initshow:true, closable:true});
        
        ColdFusion.navigate('blankpage.cfm', 'Window3');
        return false;
        
        
        "
        >
</cfform>
</body>
</html>

Open in new window

0
 
SidFishesCommented:
when I run that code on my local server, everything centers fine on all three buttons no matter what the width of the viewport.

I notice that you are applying styles to your cfwindow?  perhaps that's where the issue lies -  remove the style and see what you get

0
 
SidFishesCommented:
note: I'm running cf 8 if you're running 9 the default style may be different?
0
 
judsonmusicAuthor Commented:
How am I applying styles to them?
0
 
SidFishesCommented:
ok well it may be a version difference but there formatting is different - you running 9?

Thought if you were applying css to the window that may be causing the issue




ex2.jpg
ex1.jpg
0
 
judsonmusicAuthor Commented:
I am running 9 so what property coul I override?
0
 
judsonmusicAuthor Commented:
Adobe should be paying us. Thanks man.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.