<cffunction returnFormat="plain"

I’m moving some ACF code over to Lucee.

I have a component function that literally returns a string value from a DB lookup.

I have returnFormat=“plain” output=“false” in the cffunction header.

Under ADF the string is returned without issue.
Under Lucee the string is returned but seems to have additional empty space before it.

E.g. even if I alter it to be
<cfreturn “test string value”>

If I dump this with a JS alert on return I get the actual text several lines down the window and opposed to the top.

I can add a .trim() to it before it gets passed on but why the difference between ACF and Lucee and where are the spaces coming from?

Any ideas, many thanks?

Please enable the option Smart whitespace management in Admin → Settings → Output

A ticket in Jira [LDEV-2965] - Lucee

1 Like

Ah, of course, this is a new test Lucee environment I setup. Got that set on the ACF server, totally forgot about it on Lucee.

Many thanks :slight_smile: