" / "
and
' / '
However the same starter must end e.g.:
echo " '; is wrong
echo ' "; is wrong
echo " ' "; is right
echo ' " '; is right
echo " " ' '; is wrong - in this case echo " " . ' '; is right.
It is fairly simple to check the length of a string in PHP. All you need to do is use the function strlen(). Below is an example of how it is used. <?php $my_text = "Hello"; echo strlen($my_text); // outputs 5 ?>
Delimiter is a special character or a symbol to seperate the string
You can do this: <?php if ( $word === strrev( $word ) ) { echo "The word is a palindrome"; } else { echo "The word is not a palindrome"; }
If you will read typecasting on php, you will know more on this. <?php $str = "10"; $num = (int)$str; ?>
You can use single quotes $variable = 'string'; You can use double quotes $variable = "string"; You can use the Heredoc method $variable = <<<EOT Very Long String EOT; And you can use the Nowdoc method (after PHP 5.3.0) $variable = <<<'EOT' Very Long String EOT;
Varchar in SQL means string in PHP.
<?php trim(ereg_replace( ' +', ' ', $extraWhiteSpace)); ?>
If you will see this example as below, this may help. <?php $string = mysql_real_escape_string($string); $sql = "insert into stringtable(mystring) values('$string')"; ?>
$string ="Guess my length"; $length = strlen($string); now the $length will have the length of the string.
It is fairly simple to check the length of a string in PHP. All you need to do is use the function strlen(). Below is an example of how it is used. <?php $my_text = "Hello"; echo strlen($my_text); // outputs 5 ?>
The eval() function evaluates a string as PHP code. http://us.php.net/manual/en/function.eval.php
Delimiter is a special character or a symbol to seperate the string
A predefined function can reverse a string as shown below:echo strrev('pizza'); // outputs: azzip
The tension in any part of the string is equal to the force that pulls the string at the ends (assuming for simplicity that the string is basically weightless).
A word that starts with AN and ends with OR: ancestor.
It's a php (web script) string that turns characters into "dots" in most password fields.
Not possible through html. Use php strrev function. For eg: