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
   1234
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 javascript misc model-glue off topic personal project learn slidesix sql

Recent Comments

Adding Auto Generated Code Downloads to BlogCFC
ada5fsa said: http://www.ibiblio.org/st... http://www.ncaonline.org/...... [More]

Chinese Birth Calendar Accuracy Test
mama to be said: ok so i will be 2 months shy of 18 when i have my baby. this calendar does not technically work for ... [More]

Fixing 'User Profile Service Failed The Logon' on Vista
Mike said: That fix worked although all i did was remove .bak and reset state to 0. User was able to log in to... [More]

Chinese Birth Calendar Accuracy Test
Melissa said: Wrong for my daughter, which it predicted to be a boy... we'll see for #2. Predicts a girl (maybe, f... [More]

Adding Auto Generated Code Downloads to BlogCFC
fweerw said: http://www.ibiblio.org/st... http://www.cambodia.ait.a...... [More]

RSS


adobe community experts

coldfusionbloggers

FullAsAGoog MXNA

Consumed By Feed-Squirrel.com