added ability to use base_url