-2

Javascript window.open() auto new tab not working in Google-Chrome and bypass all browser open new tab.

** auto new tab without click button and click link **

echo '<script type="text/javascript">
          window.open("http://www.google.co.th");
      </script>';

** Run for IE "pass"

** Run for Firefox "pass"

** Run for Chrome "fail"

CodingIntrigue
  • 75,930
  • 30
  • 170
  • 176
Kung
  • 33
  • 5

1 Answers1

0

Try this

window.open('http://www.google.co.th','','height=200,width=300');

Chrome will block popup windows on page, until you give him access.

dario
  • 5,149
  • 12
  • 28
  • 32
Amarjit
  • 34
  • 7