Skip to main content

Posts

Showing posts from June, 2012

On Load Message

On Load Function Displaying Loading Message <html xmlns="http://www.w3.org/1999/xhtml" > <head runat="server"> <title></title> <script type="text/javascript"> function hideLoading() { document.getElementById('divLoading').style.display = "none"; document.getElementById('divFrameHolder').style.display = "block"; } </script> </head> <body> <form id="form1" runat="server"> <div id="divLoading"> <img src="loadingAnimation.gif" alt="" /> </div> <div id="divFrameHolder" style="display:none"> <iframe src="http://asp.net" onload="hideLoading()" frameborder="1" scrolling="no"> </iframe> </div> </form> </body>

Disable the Past Content in Text Box and Disable the right Click

Disable the Past Content in Text Box and Disable the right Click  <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <title>Untitled Document</title> <script language="javascript"> function whichButton(event) { if (event.button==2)//RIGHT CLICK { alert("Not Allow Right Click!"); } } function noCTRL(e) { var code = (document.all) ? event.keyCode:e.which; var msg = "Sorry, this functionality is disabled."; if (parseInt(code)==17) //CTRL { alert(msg); window.event.returnValue = false; } } </script> </head> <body> <form method=""> <strong>Not Allow Paste </strong><BR> <input type="text" value="" onMouseDown="whichButton(event)" onKeyDown="return noCTRL(event)"/> </form> </body> </html> OR javascript function noC