I want to raise a conditional 404 within my action if some get parameters don't meet a certain criteria. What is the best way to do this with the default error handler?
I want to raise a conditional 404 within my action if some get parameters don't meet a certain criteria. What is the best way to do this with the default error handler?
I think,
throw new CHttpException(404, 'Oops. Not found.');
Yes, that did it – how fortunate that the error code matches the http status!
Thanks a lot