bcolflesh

msg:1277905 | 8:52 pm on May 9, 2005 (gmt 0) |
$filename = $member.'.inc';
|
kazecoder

msg:1277906 | 9:52 pm on May 9, 2005 (gmt 0) |
I just wanted to add that what you are asking about is know as concatenating strings. The above will fix you up just right.
|
KrazyKid

msg:1277907 | 12:51 am on May 10, 2005 (gmt 0) |
thanks :)
|
KrazyKid

msg:1277908 | 3:55 am on Jun 5, 2005 (gmt 0) |
How do I do this correctly? echo '$game' + '/' + '$filename'; Thanks
|
ekram

msg:1277909 | 5:03 am on Jun 5, 2005 (gmt 0) |
How do I do this correctly? echo '$game' + '/' + '$filename'; Thanks <? echo $game . '/' . $filename; ?>
|
base64

msg:1277910 | 5:58 pm on Jun 5, 2005 (gmt 0) |
One more way: echo "$game/$filename";
|
mcibor

msg:1277911 | 8:29 pm on Jun 5, 2005 (gmt 0) |
If you echo the variable between ' ' then it is put as string. If you put it between " " then it is parsed as a variable: <?php $var = "This is a test"; echo 'This is a variable: $var<br>'; echo "This is what is inside: $var"; ?> |
| Also to ensure that you are doing everything correctly you can put the variable outside of the string: echo "This is what is inside: ".$var."<br>"; As you see the concatenation in php is a dot (not plus as in javascript). Best regards Michal Cibor
|
|