Router: url_for calculation changed.

fixes url building for virtual hosts