CFDiv - Something To Watch Out For

Was just trying to create a super simple dynamic region on a page when I repeatedly received the following error when I loaded the page:

error:http: Error replacing HTML, element not found: comments

I double check everything and my bind statement looks good. View Source however told me something different. CF correctly included the Ajax 'plumbing' bits to create the div and register it, but my div itself was not in the source. Turns out the template I was working with had the following on line 1:

<cfsetting enablecfoutputonly=true>

So since cfdiv actually is creating a div behind the scenes it did not get output to the page because it wasn't surrounded in a <cfoutput>. Seems strange though because none of the other CF tags that generate HTML (IE cfinput) share this behavior. Unless I'm mistaken?

Comments
I think this must be the case with the new AJAX tags as I ran into this issues yesterday when using cflayout, cflayoutarea, etc
# Posted By Sam Farmer | 1/16/08 4:51 PM
When using cfdiv to load pages, if the css is included, only FF and Opera can successfully render the styled page, IE and Safari will only show the page without styles. Is that a bug ? or IE and FF doing ajax requests differently on the back ?
# Posted By Dev | 1/27/08 6:50 PM
Dev: Can you send me a sample reproducable case in email?
# Posted By todd sharp | 1/28/08 9:43 AM
hi todd,

I have put part of the code here
http://www.box.net/shared/luemef88cc
You may download it and have a look.

Notice that when you run the code in IE and FF, you will have a different result when you click on the Join Now button. So far only FF and Opera can render the css inside regForm.cfm, but IE and Safari (Win) just ignore it.

By the way, thanks for your concern and I hope the issue can be solved.
# Posted By Dev | 2/21/08 2:24 PM
Dev: Put your <style> from regForm.cfm in the head of index.cfm and you're all set.
# Posted By todd sharp | 2/22/08 2:25 PM
Well, I have been using this before. However, I need the loaded page's css to overwrite the original css rules in index.cfm . Therefore, I can't afford to do. By the way, thanks for your answer
# Posted By Dev | 2/24/08 1:31 AM

Calendar

Sun Mon Tue Wed Thu Fri Sat
     12
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
31       

Subscribe

Enter your email address to subscribe to this blog.

Tags

actionscript ajax blogging cfsnippets coldfusion flash forms flex funny stuff misc model-glue off topic personal project learn slidesix sql

Recent Comments

Adding Auto Generated Code Downloads to BlogCFC
ada5fsa said: http://www.mountwashingto... http://extjs.com/forum/me... h... [More]

BlogCFC Survey #2
ada5fsa said: http://www.mountwashingto... http://extjs.com/forum/me... h... [More]

Most Difficult Captcha Of All Time
kokkooo said: [url=http://synchrophase.info/...]消費者金融 ブラック[/url] [url=http://geji-geji.com/]消費者金融ブラック[/url] [url=http... [More]

Most Difficult Captcha Of All Time
kokkooo said: <a href="http://synchrophase.info/...">消費者金融 ブラック</a> <a href="http://gej... [More]

Using A PlayStation 2 HDD In Your PC
Vodin said: Well dang. Thanks man, my uncle who owns a Video Game shop had a PS2 harddrive in the junk box, I sn... [More]

RSS


coldfusionbloggers

FullAsAGoog MXNA

Consumed By Feed-Squirrel.com