Not very sure how to word this question but I’ll give an example.
$string = 'Hey, $name. How are you?';
When I post this string, $name doesn’t change. How can I make it so I can put something like +name+ so it changes to the name. I’ve tried seaching for it but I don’t know what to search for so I don’t have any luck. It’s probably really simple but i’m just blanking out.
Thanks
You can use place-holders and
str_replace. Or use PHP’s built-insprintfand use%s. (And as of v4.0.6 you can swap the ordering of arguments if you’d like).And, for anyone wondering, I understood that is trouble templating a string, not PHP’s integrated concatenation/parsing. I just assume keep this answer up though as I’m still not 100% sure this OP’s intent