Sunday 29 January 2017

History of PHP Language in hindi

PHP is a server-side scripting language designed primarily for web development but also used as a general-purpose programming language. Originally created by Rasmus 

Lerdorf in 1994, the PHP reference implementation is now produced by The PHP Development Team. PHP originally stood for Personal Home Page,[5] but it now stands for 

the recursive acronym PHP: Hypertext Preprocessor.

PHP code may be embedded into HTML code, or it can be used in combination with various web template systems, web content management systems and web frameworks. PHP 

code is usually processed by a PHP interpreter implemented as a module in the web server or as a Common Gateway Interface (CGI) executable. The web server combines the 

results of the interpreted and executed PHP program, which may be any type of data, including images, with the generated web page. PHP code may also be executed with a 

History of PHP
History of PHP
command-line interface (CLI) and can be used to implement standalone graphical applications.

The standard PHP interpreter, powered by the Zend Engine, is free software released under the PHP License. PHP has been widely ported and can be deployed on most web 

servers on almost every operating system and platform, free of charge.

The PHP language evolved without a written formal specification or standard until 2014, leaving the canonical PHP interpreter as a de facto standard. Since 2014 work 

has gone on to create a formal PHP specification

Each PSR is suggested by members and voted according to an established protocol to act consistently and inline with their agreed upon processes.

Tags of PHP:

<?php 
echo"hello"

?>

<?php  = PHP open tag.
?> = PHP close tag



 and Gate more Information about php

History of PHP Program

PHP is a server-side scripting language designed primarily for web development but also used as a general-purpose programming language. Originally created by Rasmus 

Lerdorf in 1994, the PHP reference implementation is now produced by The PHP Development Team. PHP originally stood for Personal Home Page,[5] but it now stands for 

the recursive acronym PHP: Hypertext Preprocessor.

PHP code may be embedded into HTML code, or it can be used in combination with various web template systems, web content management systems and web frameworks. PHP 

code is usually processed by a PHP interpreter implemented as a module in the web server or as a Common Gateway Interface (CGI) executable. The web server combines the 

results of the interpreted and executed PHP program, which may be any type of data, including images, with the generated web page. PHP code may also be executed with a 

History of PHP
History of PHP
command-line interface (CLI) and can be used to implement standalone graphical applications.

The standard PHP interpreter, powered by the Zend Engine, is free software released under the PHP License. PHP has been widely ported and can be deployed on most web 

servers on almost every operating system and platform, free of charge.

The PHP language evolved without a written formal specification or standard until 2014, leaving the canonical PHP interpreter as a de facto standard. Since 2014 work 

has gone on to create a formal PHP specification

Each PSR is suggested by members and voted according to an established protocol to act consistently and inline with their agreed upon processes.

Tags of PHP:

<?php 
echo"hello"

?>

<?php  = PHP open tag.
?> = PHP close tag

 and Gate more Information about php

What is Php Language

PHP is a server-side scripting language designed primarily for web development but also used as a general-purpose programming language. Originally created by Rasmus 

Lerdorf in 1994, the PHP reference implementation is now produced by The PHP Development Team. PHP originally stood for Personal Home Page,[5] but it now stands for 

the recursive acronym PHP: Hypertext Preprocessor.

PHP code may be embedded into HTML code, or it can be used in combination with various web template systems, web content management systems and web frameworks. PHP 

code is usually processed by a PHP interpreter implemented as a module in the web server or as a Common Gateway Interface (CGI) executable. The web server combines the 

results of the interpreted and executed PHP code, which may be any type of data, including images, with the generated web page. PHP code may also be executed with a 

History of PHP
History of PHP
command-line interface (CLI) and can be used to implement standalone graphical applications.

The standard PHP interpreter, powered by the Zend Engine, is free software released under the PHP License. PHP has been widely ported and can be deployed on most web 

servers on almost every operating system and platform, free of charge.

The PHP language evolved without a written formal specification or standard until 2014, leaving the canonical PHP interpreter as a de facto standard. Since 2014 work 

has gone on to create a formal PHP specification

Each PSR is suggested by members and voted according to an established protocol to act consistently and inline with their agreed upon processes.

Tags of PHP:

<?php 
echo"hello"

?>

<?php  = PHP open tag.
?> = PHP close tag

Click Here and Gate more Information about php


Friday 20 January 2017

Examplre of Inner Join function in mysql

  1. SELECT foods.item_name,foods.item_unit,  
  2. company.company_name, company.company_city  
  3. FROM foods ,company  
  4. WHERE  foods.company_id =company.company_id  
  5. AND company.company_city='London';

Wednesday 11 January 2017

Jquery With Animation

jquery with animation

<div dir="ltr" style="text-align: left;" trbidi="on">
<div dir="ltr" style="text-align: left;" trbidi="on">
<br /></div>
<style>
.animation{
 width:300px;
 height:300px;
 border:#000 thin solid;
 background-color:#903;
 border-radius:50px;
 position:relative;
}
input{
 background-color:#FF0;
 margin:20px;
 padding:20px;
 border:#999 thin solid;
 border-radius:50px;
}

</style>

<script src="../jquery-classes/jquery.js"></script>
<script type="text/javascript">
$(document).ready(function(){

 var anim = $('.animation');

 $('#animation').click(function(){
 anim.animate({
  left:'600px',
  opacity:'0.7',

  });

  anim.animate({
  top:'300px',
  opacity:'0.5',

  });

  anim.animate({
  left:'0px',
  opacity:'0.1',

  });

  anim.animate({
  top:'0px',
  opacity:'1',

  });
 });
});

</script>



<body>
  <div class="animation">
  jquery animation<br />

  </div>
<input id="animation" type="button" value="Click To Animate" />

</body></div>

The Basic Input Field of Login Page

Input field in login page

<body>
<form method="post" action="#"><pre>
E-mail<input type="email" name="email" id="email" /><br />

Password<input type="password" name="password" id="pwd" /><br />
<input type="submit" name="n" value="submit"  />

</pre></body>

Monday 9 January 2017

Make the Dashboard Using Mysql

<body>
<table border="1">

<?php

if(isset($_SESSION["useremail"])){
$unm = $_SESSION["useremail"];
$qr = "select * from submit where email = '$unm' ";
$rs = mysql_query($qr);
$num = mysql_num_rows($rs);


?>
        <tr>
        <td>Name</td>
        <td>Surname</td>
        <td>Email id</td>
        <td>password</td>
        <td>Gender</td>
        <td>Phone</td>
        <td>Address</td>
        <td>File</td>
        <td>agree</td>
        <td>delete</td>
        <td>Logout</td>
        <td>Update</td>
     
        </tr>
        <?php
if ($num > 0){
while ($row = mysql_fetch_array($rs)){ ?>

                <tr>
                <td><?php echo $row["name"]; ?></td>
                <td><?php echo $row["surname"]; ?></td>
                <td><?php echo $row["email"]; ?></td>
                <td><?php echo $row["password"]; ?></td>
                <td><?php echo $row["gender"]; ?></td>
                <td><?php echo $row["phone"]; ?></td>
                <td><?php echo $row["address"]; ?></td>
                <td><?php echo $row["file"]; ?></td>
                <td><?php echo $row["agree"]; ?></td>
                 <td><a href="dashboard.php?del=<?php echo $row['id'];?>">delete</a></td>
                 <td><a href="dashboard.php?logout=0">Logout</a></td>
                 <td><a href="dashboard.php?upt=<?php echo $row['id'];?>">update</a></td>
               
                </tr>
               
<?php }} }?>

</table>


       
</body>

Beautiful Logo

This is my frist LOGO



Example of Super Global Request

<body>
<form method="post" action="<?php echo $_SERVER['PHP_SELF'];?>">
  Name: <input type="text" name="fname">
  <input type="submit">
</form>

<?php
if ($_SERVER["REQUEST_METHOD"] == "POST") {
    // collect value of input field
    $name = $_REQUEST['fname'];
    if (empty($name)) {
        echo "Name is empty";
    } else {
        echo $name;
    }
}
?>

</body>

Simple Method of Sort Array

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>

<body><?php
$s = date("D");
switch($s){
case"sunday";
echo"today is sunday";
break;
default;
echo"$s";
}
?>
<br />

<?php
$cars = array("Volvo", "BMW", "Toyota");
rsort($cars);

$clength = count($cars);
 echo"$clength";
 ?>
 <br />

 <?php
 $car = array("bat", "cat", "dot");
 echo $car[$x];
 asort($car);

 $clength  = count($car);
 for($x = 0 ;$x < $length; $x++){
 echo $car[$x];
 echo"<br>";
 }
 ?>
</body>
</html>

How to use php validation

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>

<body>

<?php
// define variables and set to empty values
$name = $email = $gender = $comment = $website = "";

if ($_SERVER["REQUEST_METHOD"] == "POST") {
  $name = test_input($_POST["name"]);
  $email = test_input($_POST["email"]);
  $website = test_input($_POST["website"]);
  $comment = test_input($_POST["comment"]);
  $gender = test_input($_POST["gender"]);
}

function test_input($data) {
  $data = trim($data);
  $data = stripslashes($data);
  $data = htmlspecialchars($data);
  return $data;
}
?>

<h2>PHP Form Validation Example</h2>
<form method="post" action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>">
  Name: <input type="text" name="name">
  <br><br>
  E-mail: <input type="text" name="email">
  <br><br>
  Website: <input type="text" name="website">
  <br><br>
  Comment: <textarea name="comment" rows="5" cols="40"></textarea>
  <br><br>
  Gender:
  <input type="radio" name="gender" value="female">Female
  <input type="radio" name="gender" value="male">Male
  <br><br>
  <input type="submit" name="submit" value="Submit">
</form>

<?php
echo "<h2>Your Input:</h2>";
echo $name;
echo "<br>";
echo $email;
echo "<br>";
echo $website;
echo "<br>";
echo $comment;
echo "<br>";
echo $gender;
?>
</body>
</html>