JavaScript Reference/Javascript Objects/location

Материал из Web эксперт
Версия от 11:22, 26 мая 2010; Admin (обсуждение | вклад) (1 версия)
(разн.) ← Предыдущая | Текущая версия (разн.) | Следующая → (разн.)
Перейти к: навигация, поиск

"location" Example

   <source lang="javascript">
   

<html> <body>

Row 1
Row 2
Row 3

<button onclick="myTable.style.fontWeight = "bold";">Bold</button> <button onclick="location.reload();">Reload page</button> </body> </html>


     </source>
   
  


"location" is applied to

   <source lang="javascript">

+----------------+--------------------------------------------------------------+ | Applied_To |document window | +----------------+--------------------------------------------------------------+

     </source>
   
  


"location" JavaScript Methods

   <source lang="javascript">

+----------------+--------------------------------------------------------------+ | JavaScript |assign reload | | Methods |replace | +----------------+--------------------------------------------------------------+

     </source>
   
  


"location" JavaScript Properties

   <source lang="javascript">

+----------------+--------------------------------------------------------------+ | JavaScript |hash host | | Properties |hostname href | | |pathname port | | |protocol search | +----------------+--------------------------------------------------------------+

     </source>
   
  


"location" Syntax and Note

   <source lang="javascript">

Note: Basic information about the current site being visited.

Syntax:

objectName.location.memberName


     </source>