Anyone have a recommendation/pattern for tracking HTTP: Referrer header data in an IHP app? I was thinking it might be best to add it to the beforeAction
in the Static
Controller
for the app landing page but it could just as well go in the initContext
in FrontController
?
I'm wondering if there is a strong technical argument for one over the other.
If you want to track it across the full application, use initContext
in FrontController
. If you only want it for specific controllers, go with beforeAction
.
From a technical standpoint there's no major difference between these two places.