Click here to Skip to main content
15,893,401 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Please Send The Code That Click On Button Or Link Or Image Then Open Site In New Window
Posted

Javascript is the best way to do.

MIDL
tmpJScript = "javascript:window.open('URL address','','left=20,top=20,width=550,height=650,status=1,resizable=1,scrollbars=1');return false;";
            LinkButton.Attributes.Add("onClick", tmpJScript);
 
Share this answer
 
like YANGQ said use javascript's window.open functionality. Here is doc [^]for you.
 
Share this answer
 
aspx page
within header
XML
<script type="text/javascript">
function NewWindow()
{
    top.window.open("http://www.google.com",'800x300','toolbar=no,scrollbars=yes,resizable=yes,status=no,location=no,menubar=no,directories=no,width=800,height=300');
}
</script>



and within form
XML
<asp:Button ID="Button1" runat="server" Text="New Window" OnClientClick="NewWindow()" />
      <input type="button" value="New Window" onclick="NewWindow()" />
      <a href="javascript:return fasle" onclick="NewWindow()"> New Window</a>
 
Share this answer
 

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