default view in every request???

Hey all, does anyone know why when coldbox runs a request (at least for us)
and it has all these built in functions it runs, why does it seem to always
call the default layout and view? I have a rc.variable on the default view
page, when i am on a separate page and run a transaction, it is producing
an error in the backend, which does not stop the processing of the request,
however, it does add a record in our error log.

not sure why coldbox always runs the default layout and view and thought
maybe someone might be able to provide me with info.

I thought i could get around this issue by setting the rc.variable right on
the default view file using a cfif not isdefinded() or rc.variable is ""
but that has not worked and produces errors...the variable is suppose to be
a query that is set in the handler file but since the default view is run,
the handler is not run, so the variable is just blank...i need data in it
so the select box on the page has a query so the loop does not error.

any info would be appreciated.


Hi there,

I am unsure what you mean; but if you don’t want to render any output in a request you can put event.noRender() in the request function of your handler.

Does that help?


not exactly, however that was interesting.
I was using the line debugger to go line by line through a submit request on our page…

if you notice when you see debug for a page to load in coldbox, there are a ton of functions that run, most of them are Coldbox system functions. One seems to set the Default Layout and View, but that also seems to run those pages in the back end. I found this using my line debugger in builder.

I am trying to figure out why the default layout and view files (these come from the coldbox.xml.cfm file in our older version) are run for the page request, or do we have something not set right in our code…

we are on version 2.6.3 so maybe things are different in 3.5.

Hope this explains it a bit more…


If you are not using the default layout in the config file, how are you changing the layout?

As for the view, the view is based on the request so if you route points to the default view then it will use the default view.