Вопрос

I was wondering how I would get the hostUrl in JavaScript which is passed from the command line

In Java, one would type System.getProperty("hostUrl"); to achieve this. What is the alternative to this in JavaScript?

Это было полезно?

Решение

I am assuming that you are searching for window.location.hostname or window.location.host.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top