07
Sep
stored in: PHP/MYSQL

Variables in PHP are represented by a dollar sign followed by the name of the variable. The variable name is case-sensitive.

<?php

$name = ‘John’;
$age = ‘23′;
$location = ‘London’;

echo ‘My name is: $name and i am $age years old, currently living in $location’;

?>

This is output the following:

My name is: John and i am 23 years old, currently living in London

Simple and Easy, try it your self ;)

Leave a Reply

You must be logged in to post a comment.