Jump to content


Photo

Adding information to a text variable.


  • Please log in to reply
2 replies to this topic

#1 revinkevin

revinkevin
  • New Members
  • Pip
  • Newbie
  • 2 posts

Posted 22 April 2006 - 01:36 PM

Is it possible in php to add information at the end of a text string.

e.g

$name=$name+" was here";

Thanks.

#2 AndyB

AndyB
  • Staff Alumni
  • Advanced Member
  • 5,465 posts
  • LocationToronto

Posted 22 April 2006 - 01:40 PM

Yes, but using the concatenation operator (a dot) like so:
$name.= " was here";

Legend has it that reading the manual never killed anyone.
My site

#3 revinkevin

revinkevin
  • New Members
  • Pip
  • Newbie
  • 2 posts

Posted 24 April 2006 - 02:03 PM

[!--quoteo(post=367444:date=Apr 22 2006, 01:40 PM:name=AndyB)--][div class=\'quotetop\']QUOTE(AndyB @ Apr 22 2006, 01:40 PM) View Post[/div][div class=\'quotemain\'][!--quotec--]
Yes, but using the concatenation operator (a dot) like so:
$name.= " was here";
[/quote]

Thanks that solved it




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users