Added body of 'toURL' method