Use pathname, not path when setting url path