I know how to get the URL of the page, but how can I extract simply the domain and the domain alone?
It must return the same value with or without www, and it must also return the same value regardless of file, with or without trailing slash, etc.
So www.domain.com
would return domain.com
, and domain.com/index.php
would return the same as well.
Is this possible?
If so, is there a way to do it without calling ExternalInterface.call('window.location.href.toString')
?
Thank you for the help!