CFERROR tag doesn't overwrite the Admin error template setting

I added this line in application.cfm
cferror type = “exception” template = “arpille_error.cfm”

I go to a forced error to check
And I still have the admin error yellow template.

Any idea why ?

Lucee 5.3.9.133
Linux debian 10

Hi Pierre, this is just a guess… Is it possible that adding the attribute exception ="any" resolves your issue? I think the docs explicitly says this attribute is required if you have attribute type="exception'.

See <cferror> :: Lucee Documentation

Just saw that the docs needs to have the values for the exception attribute added.

Yes that is : adding exception=any does work for
non existing variables or bad cfquey,
I did not try other errors,
but I think, that have solved the problem.
Thanks you.

2 Likes

Required if type = “exception” or “monitor”.

If it’s required in this case, should it not throw a compile-time exception if it’s not present?

This would have helped Pierre solve his issue faster if Lucee actually behaved the way it claimes it is supposed to in the given situation, yeah?

I’d say yes sure! Even better would be to follow ACF and have the default value of “any” for the attribute exception.

You are right.
Also, I come from an old version of ColdFusion 9,
and in my memory and what I wrote some years ago, it seems that it was not required.
Now I know.
Thanks.

Can you file a bug, let’s make this experience better.

it does looks like it was meant to default to any

Also there’s this type=“monitor” reference, which doesn’t make sense?

here’s more or less all the exception types which are natively supported by Lucee, would be good to update the core definition with the list of types, is anything missing for acf-compat?

https://helpx.adobe.com/coldfusion/cfml-reference/coldfusion-tags/tags-d-e/cferror.html

1 Like