Don't use site.url unless it is defined.