PHP is whitespace insensitive


PHP whitespace insensitive means that it almost never matters how many whitespace
characters you have in a row.one whitespace character is the same as many such characters .

For example, each of the following PHP statements that assigns the sum of 3 + 2 to the variable
$five is equivalent:


<?php
$five=3 + 2;
echo $five; //output  5
$six=2  *           3;
echo $six;  // output 6

$var="Hello         Sharda Technologies";
print $var;   //output   Hello Sharda Technologies
?>

Get More Knoweledge You Join Sharda Technologies

2 comments:

  1. Great php tutorials tips for programming. It can help better for website developers.Thanks for this useful post.

    ReplyDelete
  2. Whitespace is the stuff you type that is typically invisible on the screen, including spaces,tabs, and carriage returns (end-of-line characters). PHP’s whitespace insensitivity does not mean that spaces and such never matter. (In fact, they are crucial for separating the words in the PHP language.) Instead, it means that it almost never matters how many whitespace characters.

    php training in Chennai

    ReplyDelete