Posts

Showing posts from July, 2017

You guys need fresh code

You guys need fresh code or ideas ...just comment below.. Regards, Blogger

Php Basic Form Validation

Php Basic Form Validation  < !DOCTYPE  HTML >    < html > < head > < style > .error  { color :  #FF0000 ; } < /style > < /head > < body >    <?php // define variables and set to empty values $nameErr = $emailErr = $genderErr = $websiteErr =  "" ; $name = $email = $gender = $comment = $website =  "" ; if  ( $_SERVER [ "REQUEST_METHOD" ] ==  "POST" ) {    if  ( empty ( $_POST [ "name" ])) {     $nameErr =  "Name is required" ;   }  else  {     $name = test_input( $_POST [ "name" ]);   }       if  ( empty ( $_POST [ "email" ])) {     $emailErr =  "Email is required" ;   }  else  {     $email = test_input( $_POST [ "email" ]);   }         if  ( empty ( $_POST [ "website" ])) {  ...

Php program to take checkbox and radiio button values

Php program to take checkbox and radiio button values

LED Blinking using 8051 Microcontroller and Keil C – AT89C51

Image
LED Blinking using 8051 Microcontroller and Keil C – AT89C51 #include<reg52.h> // special function register declarations // for the intended 8051 derivative sbit LED = P2^0; // Defining LED pin void Delay(void); // Function prototype declaration void main (void) { while(1) // infinite loop { LED = 0; // LED ON Delay(); LED = 1; // LED OFF Delay(); } } void Delay(void) { int j; int i; for(i=0;i<10;i++) { for(j=0;j<10000;j++) { } } }

Java Script to make text change text color

Java Script to make text change text color Use this as js script var i = 0 ; function change () { var doc = document . getElementById ( "background" ); var color = [ "black" , "blue" , "brown" , "green" ]; doc . style . backgroundColor = color [ i ]; i = ( i + 1 ) % color . length ; } setInterval ( change , 1000 ); And This as HTML <div id = "background" > &nbsp </div>

Simple login form example in asp.net

Simple login form example in asp.net masterpage.aspx < html   xmlns ="http://www.w3.org/1999/xhtml"> < head   runat ="server"> < title > Login Form </ title > </ head > < body > < form   id ="form1"   runat ="server"> < div > < table > < tr > < td > Username: </ td > < td > < asp : TextBox   ID ="txtUserName"   runat ="server"/> < asp : RequiredFieldValidator   ID ="rfvUser"   ErrorMessage ="Please enter Username" ControlToValidate ="txtUserName"   runat ="server"   /> </ td > </ tr > < tr > < td > Password: </ td > < td > < asp : TextBox   ID ="txtPWD"   runat ="server"   TextMode ="Password"/> < asp : RequiredFieldValidator   ID ="rfvPWD"   runat ="serv...

Android Login Using JSON Php MySql

Android Login Using JSON Php MySql Php File: <?php     $hostname_localhost ="localhost";     $database_localhost ="rdias";     $username_localhost ="root";     $password_localhost ="ASHWANI";     $localhost = mysql_connect($hostname_localhost,$username_localhost,$password_localhost)     or     trigger_error(mysql_error(),E_USER_ERROR);        mysql_select_db($database_localhost, $localhost);        $username = $_POST['username'];     $password = $_POST['password'];     $query_search = "select * from login where mobile_number = '".$username."' AND password = '".$password. "'";     $query_exec = mysql_query($query_search) or die(mysql_error());     $rows = mysql_num_rows($query_exec);           if($rows == 0) { echo 'failure';     } ...