Railo 4.1.2.005 & Coldbox 3.8.0 -- Helpers not working!

For ages, I’ve had a standard helpers file that I include in my layouts.main.cfm template via includeUDF(‘helpers/helper’). This has always worked fine.

Then I deployed an app on a client’s freshly installed server with Railo 4.1.2.005 and it insists that the function I have inside my helper file isn’t found, even though it’s there.

On my own server, it worked fine (on 4.1.1). So I updated it just now to 4.1.2.005 and now I have the same problem.

The function isn’t set to private or remote or anything. The cfset seems to work fine because if I change the name of the helper file, it complains. It just can’t seem to find the function.

Anybody else have this problem?

Thanks.

Rob

And the only thing that changed is the Railo version?

What if you dump out the “variables” scope. Do you see any of your UDFs there?

If you put a dump/abort in your helper can you confirm it’s being called?

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com

Thanks for the quick reply, Brad!

I dumped variables. It’s not in there.

I put a dump just inside the helper.cfc. It never executes.

Rob

So the issue is that the methods in your helper CFC aren’t being added in. Is this in a layout or a view?

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com

Well I include it in the layout so that it’s global, but the call to the method is in a view.

Rob

So you are expecting the variables scope in the view to be shared with the variable’s scope in the surrounding layout? I’m not sure that’s a very safe assumption. I know Railo recently put in some fixes to how the variables scope is handled with closures which might have affected this.

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com

All I know is it worked before; if not now, how do you recommend I go about doing this? :slight_smile:

Rob

Have you tried setting up your helper in the ColdBox config as a global helper with the UDFLibraryFile setting? I think that setting just uses a cfm file. That will include it in every view and handler.

http://wiki.coldbox.org/wiki/ConfigurationCFC.cfm#Extension_Points_Settings

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com

Hi guys,

I have a problem of the same sort. I have an existing Coldbox application on CB 3.7, that is running fine. When I update Coldbox to 3.8, the applicationHelper (a cfc, configured globally in the coldbox.cfc), is no longer being found in any handlers, models or views.

Did something change here from 3.7 to 3.8 that I am missing? I am also running on Railo 4.1.

I was having this problem also. Turns out my helper file I was including was a .cfc, not .cfm. I changed it to a .cfm file and it worked correctly.

Byron

my applicationhelper is .cfm. never knew it could be .cfc.

No, it needs to be a cfm, NOT a cfc.

Thanks!

~Brad

ColdBox Platform Evangelist
Ortus Solutions, Corp

E-mail: brad@coldbox.org
ColdBox Platform: http://www.coldbox.org
Blog: http://www.codersrevolution.com