window.location.origin does not work on Internet Explorer.
    Follow the below code which will set the window.location.origin value by
    concatenating the portions of the URL. 
  
  
     if (!window.location.origin)
  
  
    { 
  
  
        window.location.origin =
    window.location.protocol + '//' + window.location.hostname +
    (window.location.port ? (':' + window.location.port) : ''); 
  
  
    }
  
  
 
 
No comments:
Post a Comment