What is the difference between “window.location.href” and “window.location.hash”?

For a URL like http://[www.example.com]:80/search?q=devmo#test

  • hash – returns the part of the URL that follows the # symbol, including the # symbol. You can listen for the hashchange event to get notified of changes to the hash in supporting browsers.

    Returns: #test
    
  • href – returns the entire URL.

    Returns: http://[www.example.com]:80/search?q=devmo#test
    

Read More

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)