RE: CFMX UDF Output whitespace - possible bug
The docs are wrong - in fact, they are also wrong about roles being only used in a CFC. If you read the comments, you clearly see that someone has already mentioned this. === Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc Member of Team Macromedia Email: [EMAIL PROTECTED] Blog : www.camdenfamily.com/morpheus/blog Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 05, 2003 10:25 PM To: CF-Talk Subject: RE: CFMX UDF Output whitespace - possible bug It's not a bug. Although I recommend against it - you can output directly from a UDF. Using output= allows you to spec whether or not a UDF should output anything at all. Accept that according to the documentation the output argument is supposed to be ignored when not within a CFC. http://livedocs.macromedia.com/cfmxdocs/CFML_Reference/Tags-pt145.jsp#28 5245 7 s. isaac dealey954-776-0046 new epoch http://www.turnkey.to lead architect, tapestry cms http://products.turnkey.to tapestry api is opensource http://www.turnkey.to/tapi certified advanced coldfusion 5 developer http://www.macromedia.com/v1/handlers/index.cfm?ID=21816 ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Your ad could be here. Monies from ads go to support these lists and provide more resources for the community. http://www.fusionauthority.com/ads.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: CFMX UDF Output whitespace - possible bug
Given that MX broke lots of CF5 code , in some cases without any meaningful purpose for doing so (the new Arguments class vs. the arguments array in CF5 being case in point), I don't see why that would be an issue for them. How did your code break? If you were using arguments as an array (as it was in cf5), how did it not work in MX? Another case of CFMX's new functionality not being throught all the way through (or at least not through to the same conclusions). Hrm... Someone thought it through, because according to the documentation (I'm checking the livedocs) the output attribute is supposed to be ignored accept within a CFC. The only attributes that aren't supposed to be ignored outside of a CFC are name and returntype. http://livedocs.macromedia.com/cfmxdocs/CFML_Reference/Tags-pt 145.jsp#285245 7 So it's either a functional bug, or it's a documentation bug, but it is a bug. :) Agreed - but it's a doc bug only. -Ray ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Structure your ColdFusion code with Fusebox. Get the official book at http://www.fusionauthority.com/bkinfo.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: CFMX UDF Output whitespace - possible bug
Can you show us the code? I'm not seeing that with this example: cfscript function foo() { return 1; } /cfscript cfoutput |#foo()#| /cfoutput === Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc Member of Team Macromedia Email: [EMAIL PROTECTED] Blog : www.camdenfamily.com/morpheus/blog Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 05, 2003 1:29 PM To: CF-Talk Subject: CFMX UDF Output whitespace - possible bug I'm working on a client project running CF MX on Linux What seems to be happening is that any time we use a UDF in a cfoutput, like cfoutput div|#request.ffa.appname#|/div div|#request.ff.alttext(1)#|/div div|#left(request.ff.structtourl(attributes),1)#|/div /cfoutput We get an extra space character prepended to the string returned by the UDF, i.e. the previous snippet results in this output: |ourappname| | Edit| | m| Has anyone seen anything like this before? It seems to be a new development, because I'm pretty sure I was using UDF's in cfoutput for url variables without problems last week. I've got this diagnostic info: SERVER_SOFTWARE=Apache/1.3.23 (Unix) (Red-Hat/Linux) mod_ssl/2.8.7 OpenSSL/0.9.6b DAV/1.0.3 PHP/4.0.6 mod_perl/1.26 not sure where that's from -- a coworker handed it to me... a dump of the server variables looks like this: ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Signup for the Fusion Authority news alert and keep up with the latest news in ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: CFMX UDF Output whitespace - possible bug
PS cffunction output=no name=alttext returntype=string hint=returns an alternating string dependant on whether itemid indicates an existing db record -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Thursday, 6 March 2003 7:29 a.m. To: CF-Talk Subject: CFMX UDF Output whitespace - possible bug I'm working on a client project running CF MX on Linux What seems to be happening is that any time we use a UDF in a cfoutput, like cfoutput div|#request.ffa.appname#|/div div|#request.ff.alttext(1)#|/div div|#left(request.ff.structtourl(attributes),1)#|/div /cfoutput We get an extra space character prepended to the string returned by the UDF, i.e. the previous snippet results in this output: |ourappname| | Edit| | m| Has anyone seen anything like this before? It seems to be a new development, because I'm pretty sure I was using UDF's in cfoutput for url variables without problems last week. I've got this diagnostic info: SERVER_SOFTWARE=Apache/1.3.23 (Unix) (Red-Hat/Linux) mod_ssl/2.8.7 OpenSSL/0.9.6b DAV/1.0.3 PHP/4.0.6 mod_perl/1.26 not sure where that's from -- a coworker handed it to me... a dump of the server variables looks like this: struct COLDFUSION struct APPSERVER JRun4 EXPIRATION snippage PRODUCTLEVEL Professional PRODUCTNAME ColdFusion Server PRODUCTVERSION 6,0,0,55693 ROOTDIR /opt/coldfusionmx SERIALNUMBER snippage SUPPORTEDLOCALES snippage OS struct ADDITIONALINFORMATION Linux ARCH i386 BUILDNUMBER [empty string] NAME UNIX VERSION 2.4.9-e.3enterprise s. isaac dealey954-776-0046 new epoch http://www.turnkey.to lead architect, tapestry cms http://products.turnkey.to tapestry api is opensource http://www.turnkey.to/tapi certified advanced coldfusion 5 developer http://www.macromedia.com/v1/handlers/index.cfm?ID=21816 ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq This list and all House of Fusion resources hosted by CFHosting.com. The place for dependable ColdFusion Hosting. Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: CFMX UDF Output whitespace - possible bug
You can fix this by adding output=false to your cffunction tag. === Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc Member of Team Macromedia Email: [EMAIL PROTECTED] Blog : www.camdenfamily.com/morpheus/blog Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Barney Boisvert [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 05, 2003 3:35 PM To: CF-Talk Subject: RE: CFMX UDF Output whitespace - possible bug I have seen the same problem with CFMX, although after realizing what was happening I made changes to remove it's significance. It only affects UDFs defined with CFFUNCTION, not via CFSCRIPT. The space is NOT returned by the function, it is generated by the function, so using trim() doesn't work, and calls to left() and the like don't use the space either. Here's a test case: cffunction name=ucase_tag cfargument name=s / cfreturn s / /cffunction cfscript function ucase_script(s) { return s; } /cfscript cfset theString = Hello, World! / cfoutput pre |#theString#| |#ucase_tag(theString)#| |#ucase_script(theString)#| |#trim(ucase_tag(theString))#| |#trim(ucase_script(theString))#| /pre /cfoutput Add the generated output: |Hello, World!| | Hello, World!| |Hello, World!| | Hello, World!| |Hello, World!| barneyb -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 05, 2003 11:29 AM To: CF-Talk Subject: CFMX UDF Output whitespace - possible bug I'm working on a client project running CF MX on Linux What seems to be happening is that any time we use a UDF in a cfoutput, like cfoutput div|#request.ffa.appname#|/div div|#request.ff.alttext(1)#|/div div|#left(request.ff.structtourl(attributes),1)#|/div /cfoutput We get an extra space character prepended to the string returned by the UDF, i.e. the previous snippet results in this output: |ourappname| | Edit| | m| Has anyone seen anything like this before? It seems to be a new development, because I'm pretty sure I was using UDF's in cfoutput for url variables without problems last week. I've got this diagnostic info: SERVER_SOFTWARE=Apache/1.3.23 (Unix) (Red-Hat/Linux) mod_ssl/2.8.7 OpenSSL/0.9.6b DAV/1.0.3 PHP/4.0.6 mod_perl/1.26 not sure where that's from -- a coworker handed it to me... a dump of the server variables looks like this: struct COLDFUSION struct APPSERVER JRun4 EXPIRATION snippage PRODUCTLEVEL Professional PRODUCTNAME ColdFusion Server PRODUCTVERSION 6,0,0,55693 ROOTDIR /opt/coldfusionmx SERIALNUMBER snippage SUPPORTEDLOCALES snippage OS struct ADDITIONALINFORMATION Linux ARCH i386 BUILDNUMBER [empty string] NAME UNIX VERSION 2.4.9-e.3enterprise s. isaac dealey954-776-0046 new epoch http://www.turnkey.to lead architect, tapestry cms http://products.turnkey.to tapestry api is opensource http://www.turnkey.to/tapi certified advanced coldfusion 5 developer http://www.macromedia.com/v1/handlers/index.cfm?ID=21816 ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Your ad could be here. Monies from ads go to support these lists and provide more resources for the community. http://www.fusionauthority.com/ads.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: CFMX UDF Output whitespace - possible bug
Hi Isaac, It's not a bug. It's that HTML markup inside a cffunction is displayed onscreen. Try this: cffunction name=test Hello, cfreturn Isaac /cffunction cfoutput#test()#/cfoutput -Original Message- From: Raymond Camden [mailto:[EMAIL PROTECTED] Sent: Thursday, 6 March 2003 7:51 a.m. To: CF-Talk Subject: RE: CFMX UDF Output whitespace - possible bug Can you show us the code? I'm not seeing that with this example: cfscript function foo() { return 1; } /cfscript cfoutput |#foo()#| /cfoutput === Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc Member of Team Macromedia Email: [EMAIL PROTECTED] Blog : www.camdenfamily.com/morpheus/blog Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 05, 2003 1:29 PM To: CF-Talk Subject: CFMX UDF Output whitespace - possible bug I'm working on a client project running CF MX on Linux What seems to be happening is that any time we use a UDF in a cfoutput, like cfoutput div|#request.ffa.appname#|/div div|#request.ff.alttext(1)#|/div div|#left(request.ff.structtourl(attributes),1)#|/div /cfoutput We get an extra space character prepended to the string returned by the UDF, i.e. the previous snippet results in this output: |ourappname| | Edit| | m| Has anyone seen anything like this before? It seems to be a new development, because I'm pretty sure I was using UDF's in cfoutput for url variables without problems last week. I've got this diagnostic info: SERVER_SOFTWARE=Apache/1.3.23 (Unix) (Red-Hat/Linux) mod_ssl/2.8.7 OpenSSL/0.9.6b DAV/1.0.3 PHP/4.0.6 mod_perl/1.26 not sure where that's from -- a coworker handed it to me... a dump of the server variables looks like this: ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq This list and all House of Fusion resources hosted by CFHosting.com. The place for dependable ColdFusion Hosting. Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: CFMX UDF Output whitespace - possible bug
is this a known bug? You can fix this by adding output=false to your cffunction tag. == = Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc Member of Team Macromedia Email: [EMAIL PROTECTED] Blog : www.camdenfamily.com/morpheus/blog Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: Barney Boisvert [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 05, 2003 3:35 PM To: CF-Talk Subject: RE: CFMX UDF Output whitespace - possible bug I have seen the same problem with CFMX, although after realizing what was happening I made changes to remove it's significance. It only affects UDFs defined with CFFUNCTION, not via CFSCRIPT. The space is NOT returned by the function, it is generated by the function, so using trim() doesn't work, and calls to left() and the like don't use the space either. Here's a test case: cffunction name=ucase_tag cfargument name=s / cfreturn s / /cffunction cfscript function ucase_script(s) { return s; } /cfscript cfset theString = Hello, World! / cfoutput pre |#theString#| |#ucase_tag(theString)#| |#ucase_script(theString)#| |#trim(ucase_tag(theString))#| |#trim(ucase_script(theString))#| /pre /cfoutput Add the generated output: |Hello, World!| | Hello, World!| |Hello, World!| | Hello, World!| |Hello, World!| barneyb -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 05, 2003 11:29 AM To: CF-Talk Subject: CFMX UDF Output whitespace - possible bug I'm working on a client project running CF MX on Linux What seems to be happening is that any time we use a UDF in a cfoutput, like cfoutput div|#request.ffa.appname#|/div div|#request.ff.alttext(1)#|/div div|#left(request.ff.structtourl(attributes),1)#|/di v /cfoutput We get an extra space character prepended to the string returned by the UDF, i.e. the previous snippet results in this output: |ourappname| | Edit| | m| Has anyone seen anything like this before? It seems to be a new development, because I'm pretty sure I was using UDF's in cfoutput for url variables without problems last week. I've got this diagnostic info: SERVER_SOFTWARE=Apache/1.3.23 (Unix) (Red-Hat/Linux) mod_ssl/2.8.7 OpenSSL/0.9.6b DAV/1.0.3 PHP/4.0.6 mod_perl/1.26 not sure where that's from -- a coworker handed it to me... a dump of the server variables looks like this: struct COLDFUSION struct APPSERVER JRun4 EXPIRATION snippage PRODUCTLEVEL Professional PRODUCTNAME ColdFusion Server PRODUCTVERSION 6,0,0,55693 ROOTDIR /opt/coldfusionmx SERIALNUMBER snippage SUPPORTEDLOCALES snippage OS struct ADDITIONALINFORMATION Linux ARCH i386 BUILDNUMBER [empty string] NAME UNIX VERSION 2.4.9-e.3enterprise s. isaac dealey954-776-0046 new epoch http://www.turnkey.to lead architect, tapestry cms http://products.turnkey.to tapestry api is opensource http://www.turnkey.to/tapi certified advanced coldfusion 5 developer http://www.macromedia.com/v1/handlers/index.cfm?ID=2181 6 ~~ ~~~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index. cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Your ad could be here. Monies from ads go to support these lists and provide more resources for the community. http://www.fusionauthority.com/ads.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/uns ubscribe.cfm?user=633.558.4 s. isaac dealey954-776-0046 new epoch http://www.turnkey.to lead architect, tapestry cms http://products.turnkey.to tapestry api is opensource http://www.turnkey.to/tapi certified advanced coldfusion 5 developer http://www.macromedia.com/v1/handlers/index.cfm?ID=21816 ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Get the mailserver that powers this list at http://www.coolfusion.com Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: CFMX UDF Output whitespace - possible bug
If that were the case, it should have a big long string of carriage returns and spaces in front of the returned value ... Though I suppose I could try using cfsilent to test the theory... But content inside the cffunction shouldn't be output unless it's within a writeoutput() function. Is this a known bug? Hi Isaac, It's not a bug. It's that HTML markup inside a cffunction is displayed onscreen. Try this: cffunction name=test Hello, cfreturn Isaac /cffunction cfoutput#test()#/cfoutput -Original Message- From: Raymond Camden [mailto:[EMAIL PROTECTED] Sent: Thursday, 6 March 2003 7:51 a.m. To: CF-Talk Subject: RE: CFMX UDF Output whitespace - possible bug Can you show us the code? I'm not seeing that with this example: cfscript function foo() { return 1; } /cfscript cfoutput |#foo()#| /cfoutput == = Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc Member of Team Macromedia Email: [EMAIL PROTECTED] Blog : www.camdenfamily.com/morpheus/blog Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 05, 2003 1:29 PM To: CF-Talk Subject: CFMX UDF Output whitespace - possible bug I'm working on a client project running CF MX on Linux What seems to be happening is that any time we use a UDF in a cfoutput, like cfoutput div|#request.ffa.appname#|/div div|#request.ff.alttext(1)#|/div div|#left(request.ff.structtourl(attributes),1)#|/div /cfoutput We get an extra space character prepended to the string returned by the UDF, i.e. the previous snippet results in this output: |ourappname| | Edit| | m| Has anyone seen anything like this before? It seems to be a new development, because I'm pretty sure I was using UDF's in cfoutput for url variables without problems last week. I've got this diagnostic info: SERVER_SOFTWARE=Apache/1.3.23 (Unix) (Red-Hat/Linux) mod_ssl/2.8.7 OpenSSL/0.9.6b DAV/1.0.3 PHP/4.0.6 mod_perl/1.26 not sure where that's from -- a coworker handed it to me... a dump of the server variables looks like this: ~~ ~~~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index. cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq This list and all House of Fusion resources hosted by CFHosting.com. The place for dependable ColdFusion Hosting. Unsubscribe: http://www.houseoffusion.com/cf_lists/uns ubscribe.cfm?user=633.558.4 s. isaac dealey954-776-0046 new epoch http://www.turnkey.to lead architect, tapestry cms http://products.turnkey.to tapestry api is opensource http://www.turnkey.to/tapi certified advanced coldfusion 5 developer http://www.macromedia.com/v1/handlers/index.cfm?ID=21816 ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq This list and all House of Fusion resources hosted by CFHosting.com. The place for dependable ColdFusion Hosting. Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: CFMX UDF Output whitespace - possible bug
Have you had a look at the HTML markup? I would assume there *is* a big long string of carriage returns and spaces in front of the returned value in there. But content inside the cffunction shouldn't be output unless it's within a writeoutput(). You mean if you were Macromedia, that's how you'd write it? One could argue that the writeOutput() is implied by your not employing the output attribute of the cffunction tag. -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Thursday, 6 March 2003 12:07 p.m. To: CF-Talk Subject: RE: CFMX UDF Output whitespace - possible bug If that were the case, it should have a big long string of carriage returns and spaces in front of the returned value ... Though I suppose I could try using cfsilent to test the theory... But content inside the cffunction shouldn't be output unless it's within a writeoutput() function. Is this a known bug? Hi Isaac, It's not a bug. It's that HTML markup inside a cffunction is displayed onscreen. Try this: cffunction name=test Hello, cfreturn Isaac /cffunction cfoutput#test()#/cfoutput -Original Message- From: Raymond Camden [mailto:[EMAIL PROTECTED] Sent: Thursday, 6 March 2003 7:51 a.m. To: CF-Talk Subject: RE: CFMX UDF Output whitespace - possible bug Can you show us the code? I'm not seeing that with this example: cfscript function foo() { return 1; } /cfscript cfoutput |#foo()#| /cfoutput == = Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc Member of Team Macromedia Email: [EMAIL PROTECTED] Blog : www.camdenfamily.com/morpheus/blog Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 05, 2003 1:29 PM To: CF-Talk Subject: CFMX UDF Output whitespace - possible bug I'm working on a client project running CF MX on Linux What seems to be happening is that any time we use a UDF in a cfoutput, like cfoutput div|#request.ffa.appname#|/div div|#request.ff.alttext(1)#|/div div|#left(request.ff.structtourl(attributes),1)#|/div /cfoutput We get an extra space character prepended to the string returned by the UDF, i.e. the previous snippet results in this output: |ourappname| | Edit| | m| Has anyone seen anything like this before? It seems to be a new development, because I'm pretty sure I was using UDF's in cfoutput for url variables without problems last week. I've got this diagnostic info: SERVER_SOFTWARE=Apache/1.3.23 (Unix) (Red-Hat/Linux) mod_ssl/2.8.7 OpenSSL/0.9.6b DAV/1.0.3 PHP/4.0.6 mod_perl/1.26 not sure where that's from -- a coworker handed it to me... a dump of the server variables looks like this: ~~ ~~~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index. cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq This list and all House of Fusion resources hosted by CFHosting.com. The place for dependable ColdFusion Hosting. Unsubscribe: http://www.houseoffusion.com/cf_lists/uns ubscribe.cfm?user=633.558.4 s. isaac dealey954-776-0046 new epoch http://www.turnkey.to lead architect, tapestry cms http://products.turnkey.to tapestry api is opensource http://www.turnkey.to/tapi certified advanced coldfusion 5 developer http://www.macromedia.com/v1/handlers/index.cfm?ID=21816 ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Get the mailserver that powers this list at http://www.coolfusion.com Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: CFMX UDF Output whitespace - possible bug
content within cffunction is displayed like normal content by default. setting the output attribute to true will make it execute as if the CFFUNCTION tag internally included a CFOUTPUT. Setting output to false will make everything be hidden, like using CFSILENT. The reason (i think) you get one space is that CF compresses all runs of CF tags and interim whitespace into a single space on the HTML stream. So, CFFUNCTION is behaving in perfect consistency with the rest of CF, although I think it should be treated as a special case, and not output anything unless the output option is explicitly set to true. 'course, it's too late for that, since it'll undoubtedly break existing code. Another case of CFMX's new functionality not being throught all the way through (or at least not through to the same conclusions). banreyb -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 05, 2003 4:07 PM To: CF-Talk Subject: RE: CFMX UDF Output whitespace - possible bug If that were the case, it should have a big long string of carriage returns and spaces in front of the returned value ... Though I suppose I could try using cfsilent to test the theory... But content inside the cffunction shouldn't be output unless it's within a writeoutput() function. Is this a known bug? Hi Isaac, It's not a bug. It's that HTML markup inside a cffunction is displayed onscreen. Try this: cffunction name=test Hello, cfreturn Isaac /cffunction cfoutput#test()#/cfoutput -Original Message- From: Raymond Camden [mailto:[EMAIL PROTECTED] Sent: Thursday, 6 March 2003 7:51 a.m. To: CF-Talk Subject: RE: CFMX UDF Output whitespace - possible bug Can you show us the code? I'm not seeing that with this example: cfscript function foo() { return 1; } /cfscript cfoutput |#foo()#| /cfoutput == = Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc Member of Team Macromedia Email: [EMAIL PROTECTED] Blog : www.camdenfamily.com/morpheus/blog Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 05, 2003 1:29 PM To: CF-Talk Subject: CFMX UDF Output whitespace - possible bug I'm working on a client project running CF MX on Linux What seems to be happening is that any time we use a UDF in a cfoutput, like cfoutput div|#request.ffa.appname#|/div div|#request.ff.alttext(1)#|/div div|#left(request.ff.structtourl(attributes),1)#|/div /cfoutput We get an extra space character prepended to the string returned by the UDF, i.e. the previous snippet results in this output: |ourappname| | Edit| | m| Has anyone seen anything like this before? It seems to be a new development, because I'm pretty sure I was using UDF's in cfoutput for url variables without problems last week. I've got this diagnostic info: SERVER_SOFTWARE=Apache/1.3.23 (Unix) (Red-Hat/Linux) mod_ssl/2.8.7 OpenSSL/0.9.6b DAV/1.0.3 PHP/4.0.6 mod_perl/1.26 not sure where that's from -- a coworker handed it to me... a dump of the server variables looks like this: ~~ ~~~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index. cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq This list and all House of Fusion resources hosted by CFHosting.com. The place for dependable ColdFusion Hosting. Unsubscribe: http://www.houseoffusion.com/cf_lists/uns ubscribe.cfm?user=633.558.4 s. isaac dealey954-776-0046 new epoch http://www.turnkey.to lead architect, tapestry cms http://products.turnkey.to tapestry api is opensource http://www.turnkey.to/tapi certified advanced coldfusion 5 developer http://www.macromedia.com/v1/handlers/index.cfm?ID=21816 ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Your ad could be here. Monies from ads go to support these lists and provide more resources for the community. http://www.fusionauthority.com/ads.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: CFMX UDF Output whitespace - possible bug
It's not a bug. Although I recommend against it - you can output directly from a UDF. Using output= allows you to spec whether or not a UDF should output anything at all. === Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc Member of Team Macromedia Email: [EMAIL PROTECTED] Blog : www.camdenfamily.com/morpheus/blog Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 05, 2003 6:08 PM To: CF-Talk Subject: RE: CFMX UDF Output whitespace - possible bug is this a known bug? You can fix this by adding output=false to your cffunction tag. == = Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc Member of Team Macromedia Email: [EMAIL PROTECTED] Blog : www.camdenfamily.com/morpheus/blog ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Get the mailserver that powers this list at http://www.coolfusion.com Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: CFMX UDF Output whitespace - possible bug
It's not a bug. Although I recommend against it - you can output directly from a UDF. Using output= allows you to spec whether or not a UDF should output anything at all. Accept that according to the documentation the output argument is supposed to be ignored when not within a CFC. http://livedocs.macromedia.com/cfmxdocs/CFML_Reference/Tags-pt145.jsp#285245 7 s. isaac dealey954-776-0046 new epoch http://www.turnkey.to lead architect, tapestry cms http://products.turnkey.to tapestry api is opensource http://www.turnkey.to/tapi certified advanced coldfusion 5 developer http://www.macromedia.com/v1/handlers/index.cfm?ID=21816 ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Your ad could be here. Monies from ads go to support these lists and provide more resources for the community. http://www.fusionauthority.com/ads.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: CFMX UDF Output whitespace - possible bug
content within cffunction is displayed like normal content by default. setting the output attribute to true will make it execute as if the CFFUNCTION tag internally included a CFOUTPUT. Setting output to false will make everything be hidden, like using CFSILENT. The reason (i think) you get one space is that CF compresses all runs of CF tags and interim whitespace into a single space on the HTML stream. So, CFFUNCTION is behaving in perfect consistency with the rest of CF, although I think it should be treated as a special case, and not output anything unless the output option is explicitly set to true. 'course, it's too late for that, since it'll undoubtedly break existing code. Given that MX broke lots of CF5 code , in some cases without any meaningful purpose for doing so (the new Arguments class vs. the arguments array in CF5 being case in point), I don't see why that would be an issue for them. Another case of CFMX's new functionality not being throught all the way through (or at least not through to the same conclusions). Hrm... Someone thought it through, because according to the documentation (I'm checking the livedocs) the output attribute is supposed to be ignored accept within a CFC. The only attributes that aren't supposed to be ignored outside of a CFC are name and returntype. http://livedocs.macromedia.com/cfmxdocs/CFML_Reference/Tags-pt145.jsp#285245 7 So it's either a functional bug, or it's a documentation bug, but it is a bug. :) Thanks for the info tho. banreyb -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 05, 2003 4:07 PM To: CF-Talk Subject: RE: CFMX UDF Output whitespace - possible bug If that were the case, it should have a big long string of carriage returns and spaces in front of the returned value ... Though I suppose I could try using cfsilent to test the theory... But content inside the cffunction shouldn't be output unless it's within a writeoutput() function. Is this a known bug? Hi Isaac, It's not a bug. It's that HTML markup inside a cffunction is displayed onscreen. Try this: cffunction name=test Hello, cfreturn Isaac /cffunction cfoutput#test()#/cfoutput -Original Message- From: Raymond Camden [mailto:[EMAIL PROTECTED] Sent: Thursday, 6 March 2003 7:51 a.m. To: CF-Talk Subject: RE: CFMX UDF Output whitespace - possible bug Can you show us the code? I'm not seeing that with this example: cfscript function foo() { return 1; } /cfscript cfoutput |#foo()#| /cfoutput === === = Raymond Camden, ColdFusion Jedi Master for Mindseye, Inc Member of Team Macromedia Email: [EMAIL PROTECTED] Blog : www.camdenfamily.com/morpheus/blog Yahoo IM : morpheus My ally is the Force, and a powerful ally it is. - Yoda -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 05, 2003 1:29 PM To: CF-Talk Subject: CFMX UDF Output whitespace - possible bug I'm working on a client project running CF MX on Linux What seems to be happening is that any time we use a UDF in a cfoutput, like cfoutput div|#request.ffa.appname#|/div div|#request.ff.alttext(1)#|/div div|#left(request.ff.structtourl(attributes),1)#|/d iv /cfoutput We get an extra space character prepended to the string returned by the UDF, i.e. the previous snippet results in this output: |ourappname| | Edit| | m| Has anyone seen anything like this before? It seems to be a new development, because I'm pretty sure I was using UDF's in cfoutput for url variables without problems last week. I've got this diagnostic info: SERVER_SOFTWARE=Apache/1.3.23 (Unix) (Red-Hat/Linux) mod_ssl/2.8.7 OpenSSL/0.9.6b DAV/1.0.3 PHP/4.0.6 mod_perl/1.26 not sure where that's from -- a coworker handed it to me... a dump of the server variables looks like this: ~~~ ~~~ ~~~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid =4 Subscription: http://www.houseoffusion.com/cf_lists/index. cfm?method=subscribeforumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq This list and all House of Fusion resources hosted by CFHosting.com. The place for dependable ColdFusion Hosting. Unsubscribe: http://www.houseoffusion.com/cf_lists/uns ubscribe.cfm?user=633.558.4 s. isaac dealey954-776-0046 new epoch http://www.turnkey.to lead architect, tapestry cms http://products.turnkey.to tapestry api is opensource http://www.turnkey.to/tapi certified advanced coldfusion 5 developer http://www.macromedia.com/v1/handlers/index.cfm?ID=21816