added "base url" to handle relative urls