| 1 |
wakaba |
1.1 |
<!DOCTYPE html> |
| 2 |
|
|
<html lang="en"> |
| 3 |
|
|
<head> |
| 4 |
|
|
<title>document.domain</title> |
| 5 |
|
|
</head> |
| 6 |
|
|
<body> |
| 7 |
|
|
<p><script type="text/javascript"> |
| 8 |
|
|
if (typeof (document.domain) == 'undefined') { |
| 9 |
|
|
document.write ('You do not have <code>document.domain</code>.'); |
| 10 |
|
|
} else if (document.domain == null) { |
| 11 |
|
|
document.write ('<code>document.domain</code> is <code>null</code>.'); |
| 12 |
|
|
} else if (document.domain == '') { |
| 13 |
|
|
document.write ('<code>document.domain</code> is an empty string.'); |
| 14 |
|
|
} else { |
| 15 |
|
|
document.write ('<code>document.domain</code> is <code>'); |
| 16 |
|
|
document.write (document.domain.replace ('&', '&') |
| 17 |
|
|
.replace ('<', '<')); |
| 18 |
|
|
document.write ('</code>.'); |
| 19 |
|
|
} |
| 20 |
|
|
</script></p> |
| 21 |
|
|
</body> |
| 22 |
|
|
</html> |