ISSUE-5231: Fixed Upgrading when subsite URL contains underscore and hyphens.

Tracker link - http://atutor.ca/atutor/mantis/view.php?id=5231 . 

While creating a new subsite with underscores and hyphens are allowed in URL but are not allowed while upgrading which blocks the upgrade.

Issue is fixed by changing get_valid_url function and adding hyphen and underscore.