Skip to main content

Posts

Showing posts from September, 2012

Bike Race Game Script

<script src="//www.gmodules.com/ig/ifr?url=http://learningphp.freehosting.com/bikerace.xml&amp;synd=open&amp;w=500&amp;h=500&amp;title=bikerace& amp;border=%23ffffff%7C3px%2C1px+solid+%23999999&amp;output=js"></script>  Demo:

Superfishing Game Script

<script src="//www.gmodules.com/ig/ifr?url=http://learningphp.freehosting.com/superfishing.xml&amp;synd=open&amp;w=500&amp;h=500&amp;title=Superfishing&amp;border=%23ffffff%7C3px%2C1px+solid+%23999999&amp;output=js"></script>  Demo:

Dot Net FrameWork

The .NET Framework has two main components: the 1)Common Language Runtime (CLR) and the 2).NET Framework class library. The .NET Framework provides a Runtime environment called the Common Language Runtime or (CLR) that handles the execution of the code and provides useful services for the implementation of the application. CLR: The Runtime can be considered an agent that manages code at execution time. Thus providing core services such as memory management, thread management, and remoting. Also incorporating strict type safety, security and robustness. The Common Language Runtime (CLR) is the virtual machine component of the .NET framework. All .NET programs execute under the supervision of the CLR, guaranteeing certain properties and behaviors in the areas of memory management, security, and exception handling. Class Library: The class library is a comprehensive collection of reusable types that you can use to develop traditional command-line, WinForm (graphical user interface) appli...

PacMan Game Script.

Game Script: <script src="//www.gmodules.com/ig/ifr?url=http://learningphp.freehosting.com/pacman.xml&amp;synd=open&amp;w=500&amp;h=500&amp;title=PacMan&amp;border=%23ffffff%7C3px%2C1px+solid+%23999999&amp;output=js"></script> Demo:

Accept Only Alphabets In Text-Box

This is example used to validate a textbox which contain a alphabets. Javascript function AllowAlphabet(e)  {  isIE=document.all? 1:0 keyEntry = !isIE? e.which:event.keyCode;  if (String.fromCharCode(keyEntry).match(/^[a-zA-Z]+$/) || keyEntry == 8 || keyEntry == 32 || keyEntry == 0) { return true;  } else { return false; }  } Html Code: <input type="text" id="txtemail"  onkeypress="return AllowAlphabet(event)" />   Demo:

Javascript Email Validation

This is example used to validate a textbox which contain a valid or in-valid email address. Javascript: function validate()   {  var EmaiAddress=document.getElementById("txtemail").value; var RegExEmail =/\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*/;  if (!RegExEmail.test(EmaiAddress))   {  alert("Please Enter Valid E-mail Adress");   document.form1.txtemail.focus();  return false;   }  else  {  alert("Valid Email");   }  }  Html Code: <input type="text" id="txtemail"  /> <input type="button"  onclick="return validate();"/>    Demo:

Accept only numbers in an textbox.

This javascript function is used to make an text-box to accept number alone. JavaScript: function isNumberKey(evt)                                          {                                             var charCode = (evt.which) ? evt.which : event.keyCode                                             if (charCode > 31 && (charCode < 48 || charCode > 57))                        ...

Stop Marquee Tag On Hover Function

This example allows the user to stop the marquee tag function.when mouse  hover with their cursor (i.e. onmouseover). The marquee then continues when the user hovers away from the marquee (i.e. onmouseout). Javascript Code:   <div class="demo" style=" cursor:pointer;">                                    <marquee id="mymarquee" behavior="scroll" direction="left" scrollamount="3" width="500"><p onMouseOver="document.getElementById('mymarquee').stop();" onMouseOut="document.getElementById('mymarquee').start()"><span style="color:#006633;"> Self- Actualization training! Must for students, corporate executives, business people, self employed & all success loving people! Visa to ACHIEVEMORE!                     ...

SQL Datediff Function

The DATEDIFF function is used to calculate the difference between two date in SQL Server. The syntax is given below DATEDIFF (datepart, expression1, expression2) <expression1> and <expression2> is some date, time, or datetime. datepart abbreviation year yy, yyyy quarter qq, q month mm, m dayofyear dy, y day dd, d week wk, ww hour hh minute mi, n second ss, s millisecond ms microsecond mcs nanosecond ns TZoffset tz ISO_WEEK isowk, isoww Example: Query: SELECT DATEDIFF ( day , '2012-09-18' , '2012-09-28' ); OUTPUT:10

SQL DATEADD Function

The DATEADD function is used to add an interval to a date in MS SQL SERVER The usage for the DATEADD function is DATEADD (datepart, number, expression) where the data type of <expression> is some type of date, time, or datetime. <number> is an integer (can be positive or negative). <datepart> can be one of the following: datepart abbreviation year yy, yyyy quarter qq, q month mm, m dayofyear dy, y day dd, d week wk, ww hour hh minute mi, n second ss, s millisecond ms microsecond mcs nanosecond ns TZoffset tz ISO_WEEK isowk, isoww The result returned has the same data type as <expression>. SQL DATEADD Syntax DATEADD ( datepart , number , date ) Que...