Add a hook on before display page