Issue:
When you invoke following JS codes in original page,
1 | <a href="javascript:window.open('child.html');"> |
you can open child.html inside a new widow, but original page will loads following text instead of original content.
1 | text [object window] |
Reason:
This problem is caused by the return value of Open function.
Solution:
Set ‘void’ as the return type of open function in mandatorily.
1 | <a href="javascript:void(window.open('child.html'));"> |