Link to home
Start Free TrialLog in
Avatar of g00r00
g00r00

asked on

Working with strings!

Very easy question!

How to combine two strings;

I've got one string like which is "25" and second string like "3" how can I put them together and get "253" insted of "28"

Thank you!!!
Avatar of Batalf
Batalf
Flag of United States of America image

example:

$a = "25";
$b = "3";

$c = $a.$b;

echo $c;

use "." for concatination instead of "+" which is for arithmetic.
Avatar of g00r00
g00r00

ASKER

what if I need to put "_" betwin them, so they would look like

25_3

ASKER CERTIFIED SOLUTION
Avatar of Batalf
Batalf
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial