php basics

Code for index1.php
echo "hello world <br/>";
$str1 = "vinod";
$str2 = "kotiya";
echo $str1." ".$str2;
if (time()%2 == 0)
echo " <br/> Even Time is " . time();
echo "<br/> Odd time is " . time();

for($i=0; $i < 5 ; $i++)
echo "<br/> value of i is " . $i;

echo "<br/> Add : " . add(2,3);
function add($i,$j)
return $i+$j;

<form action="index2.php" method="post">
Name : <input type="text" name="name" /><br/>
Last Name: <input type="text" name="lname" /><br/>
<input type="submit" value="send" />
code for index2.php

echo "your name is " . $_POST["name"];
echo "<br/> surname is " . $_POST["lname"];


Most Viewed Post

solution for facebook waiting

Connect Sony XPLOD MEX-BT2500 Bluetooth CD Receiver with ur mobile

Crystal Report : Show data horizontally (Left to right) i.e. columns as rows

Google+ Followers