View Full Version : concatinate

12-28-2006, 10:11 AM
I have two bits of info I want added together to from a string in my XHTML.

This, which retrieves a variable...
$track = $_GET['track'];

and this
$URL = "http://www.buildrebuild.com/mp3/"

Will this work?
<?php echo($URL + $track); ?>

Or do I use...
<?php echo($URL.$track); ?>

Thx in advance,

12-28-2006, 10:22 AM
In php you use dot. All you had to do was do a search on php.net for concatenate. Sometimes you can answer your own question by doing a little research yourself. Please do so in the future. Try things out. See if something works or not.

<?php echo $URL.$track; ?>
No need for the parentheses around the echo either.

12-28-2006, 11:17 AM
I usually do a search. My head is fried at the mo'. No excuses...and thanks for the reply.


EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum