![]() |
|
|
+ Search |
![]()
|
Mar 15th, 2008 17:58
ha mo, Philip Olson, ssp2000 ssp2000,
By using simple string concatenation, for example:
$a = 'apple';
$b = 'banana';
$c = $a . ':' . $b;
echo $c; // apple:banana
Or create your own function to do the same:
function concat_mystrings($str1, $str2, $glue = ':') {
return $str1 . $glue . $str2;
}
echo concat_mystrings('a','b');
Also see the manual page on string operators:
String Operators:
-------------------------------------------------------------------
http://www.php.net/manual/en/language.operators.string.php
http://www.tantofa.com
http://www.fantofa.com
http://www.mantofa.com
http://www.tanpola.com
http://www.tampola.com
http://www.mozmar.com
http://www.yamot.com
http://www.templatestemp.com