Click here to Skip to main content
15,885,885 members
Please Sign up or sign in to vote.
5.00/5 (1 vote)
Hi All, I am sending link on mail. when user click on link. I want it will open new separate browser window with fixed height & width.

I tried all code but it is opening new tab . Kindly suggest. Thanks

What I have tried:

HTML
<script language='javascript'>
    function open() {
        window.open('tcrv.aspx?id=1', 'width=200, height=200, menubar=no, resizable=yes')
    }</script>*@

<script>
    function openwin() {
       myWindow = window.open("http://localhost:32354/Test1/Index", ",", "menubar=1,resizable=1,width=500,height=350");
        //this.close();
        myWindow.opener.document.write('<p>This is old window</p>');


    }
</script>

<table>
    <tr>
        <td>
           

            <a href="#">Click Here</a>
            <a href="">Go</a>;

            <a href="http://google.com/">
               >Go1</a>
            
            <a href="#">test</a>

            <a href="print.html"> Print</a>

            

            
        </td>
    </tr>
</table>
Posted
Updated 26-Jul-16 21:31pm
v2

1 solution

Try following & see if it helps-
HTML
<a href="#" onclick="window.open('http://google.com/','Google','resizable,height=350,width=500'); return false;">Open Google</a><noscript>No Javascript support<a href="http://google.com/" target="_blank">Open Google</a></noscript>

Hope, it helps :)
 
Share this answer
 
Comments
Saurabh Gupta1 27-Jul-16 3:39am    
Hi Suvendu Thanks for reply. :)
But problem still same , it is opening new tab. I want separate browser popup window.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900