Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Annoying spaces with CF 4.5

Status
Not open for further replies.

programmher

Programmer
May 25, 2000
235
US
Is anyone else experiencing this?

It seems whenever I "save as" with CF 4.5, and open my pages later, there are often HUNDREDS of blank spaces in my pages.

I think this only happens when I use "save as"; but, I am not sure...

Has anyone else experienced this? If so, what remedy (if any) did you apply?
 
What are you referring to when you say "Save As" from CF 4.5. Do you mean saving files from within CF Studio or Homesite? This sounds like it is an editor problem and not a CF issue.

GJ
 
Sometimes when viewing the source of .cfm files from the web I'll find that if the programmer has used many <CFIF>'s in the code it'll leave blank spaces where the alternative code would have appeared.

Perhaps this is what you are referring to?


Peter Toby
webmaster@petertoby.com.au
My site is under construction but getting better!
 
either peter's idea or maybe look for an option and uncheck the &quot;add extra spaces at the end of lines&quot; (not joking, i don't remember if it was cf studio or another editor but i've seen this !)
 
We were having this problem as well in Studio. I had checked with other CF developers and within forums and found no one with the same problem. So, we changed some settings ourselves. Here is what we have experienced while changing file settings around within Studio (is Studio what you are using?).

Under &quot;Options&quot;, &quot;Settings&quot;, &quot;File Setting&quot;..
There is an option that allows you to change the 'format when saving' to PC, Mac or Unix. This option was set to PC for us and was creating that tremendous amount of annoying whitespace upon saving that you are also experiencing. When we changed the setting to Unix and saved our files, the whitespace was no longer generated, but it caused complications in our cfmail tags. Finally, we have left this setting on 'Mac'. One problem here now though is that our error displays in browsers do not read line numbers correctly. For example, the error may be found on line 1 position 22,000,003,303, making error corrections difficult. But ethe ditor does display the file as I had saved it. Whoo hoo!

So maybe you can play around with these settings and stop that white space from being generated upon saving. Good luck and keep me posted on what worked for you!
 
Many thanks to Jamie, Iza, Peter, and GunJack for your comments and suggestions! I will try these and let you know what happens!
 
I have recently been experienceing the same &quot;whitespace&quot;
problem and have found that there are many many pages devoted to this topic in the allaire forums. I ended up having to use two different tags;
<cfsetting enablecfoutputonly=&quot;yes&quot;>
cold fusion code goes here
<cfsetting enablecfoutputonly=&quot;no&quot;> or you can go here and get a custom tag that I also used! <cf_StripWhiteSpace>
Hope this helps!
happy.gif
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top