Hi All,
Sorry to disturb you guys. But I have to. Well, I am new to PHP.
I wrote
------------------------------
<?php
$a=" Biswa Dutta Jena ";
echo("<b>".trim($a)."</b>");
echo(htmlspecialchars("dfgdgdfgd",ent_quotes));
?>
-------------------------------
Is this wrong?
I am finding error.
Sorry to disturb you.
Bye
One new
Moderator: General Moderators
- twigletmac
- Her Royal Site Adminness
- Posts: 5371
- Joined: Tue Apr 23, 2002 2:21 am
- Location: Essex, UK
Hi, all that's wrong is that you used the wrong case for a constant (ent_quotes instead of ENT_QUOTES), try
Oh and to save you some typing, echo doesn't require parenthesis around the information in order to work.
Enjoy learning PHP
,
Mac
Code: Select all
<?php
$a = 'Biswa Dutta Jena';
echo '<b>'.trim($a).'</b>';
echo htmlspecialchars('dfgdgdfgd', ENT_QUOTES);
?>Enjoy learning PHP
Mac