Get base URL automatically from PHP set variable