Jump to content

Can someone tell me why this doesn't work?


Beauford

Recommended Posts

Can someone explain why the first example below works and the second doesn't. The second example doesn't remove the spaces.

 

Thanks.

 

echo $trimmed = trim($c['usr2']);

 

echo"<td width='34%'>".$gangPREF."<a href='../viewuser.php?u={$c['uid2']}' {$csscode[$c['ul2']-1]}>  ".trim($c['usr2'])."</a> [{$c['uid2']}] {$RM}</td>

Why don't you make double sure that $c['usr2'] has what you expect it to have in it?

 

echo "***<br/>" . htmlentities( $c['usr2'], ENT_QUOTES ) . "<br />***<br />";
echo "***<br/>" . htmlentities( trim( $c['usr2'] ), ENT_QUOTES ) . "<br />***<br />";

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.