I think using $base_url is probably easiest, but either of the three methods above is fine.