Sexy ColdFusion 8 Ajax
Posted By : todd sharp Posted At : February 13, 2008 2:44 PM Posted In: Ajax, ColdFusion
11
Many folks have asked recently how I worked around the - umm - 'plain' look of the ColdFusion 8 Ajax controls. I originally planned on that being a part of my cf.Objective() Ajax presentation, but what the heck, I may as well show it now.
It's actually quite simple. Ext ships with several 'themes'. To use these with your Ajax controls, just include them on your page.
For the 'aero' theme:
How 'bout a Vista theme?
A few words of caution though. The first caution is to make sure you have all of the latest hot fixes applied for CF 8. There is a fix in one of them that makes sure your user included stylesheets are included after the CF added ones. This is important! (A workaround is to write your stylesheet to the <head> with <cfhtmlhead> - that should put your sheet after the CF stuff). The other thing to watch out for is to make sure the path to the necessary images is not altered (if you move the theme to your project directory instead of pointing at /CFIDE). If you don't maintain the image path, then you will need to change the path in the local stylesheet (and move the images local to your project).



/CFIDE/scripts/ajax/ext/resources/css/ytheme-aero.css
Not sure why - I think it ships as an X when you download Ext off their site. But thought I would point this out in case anyone else runs into the same thing.
That can produce some weird looking styles...
Like I said, the only difference was that I had to include the stylesheet with a leading 'y' instead of an 'x', such as 'ytheme-aero.css'. Also, my installation is running on a centOS server - maybe that has something to do with it ??
I checked the paths and they are right.
http://www.danvega.org/blog/index.cfm/2008/2/13/Ex...
<cfsavecontent variable="stylesheet">
<link href="/CFIDE/scripts/ajax/ext/resources/css/xtheme-aero.css" rel="stylesheet" type="text/css">
</cfsavecontent>
<cfhtmlhead text="#stylesheet#" />
any help would be appreciated.