Make user_agent accessible

Adding a tracker method to retrieve the user agent.
Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.