Fungsi getPort() WMLScript
Fungsi getPort() mengembalikan port yang ditentukan dalam URL.
Sintaks
n = URL.getPort(url)
Komponen | Deskripsi |
---|---|
n | String yang dipulang oleh fungsi. |
url | Sebuah string. |
Contoh
var a = URL.getPort("http://codew3c.com:80"); var b = URL.getPort("http://codew3c.com");
Hasil
a = "80" b = ""