Concatonate a string to PHP variable
I have the code below, and I want to add tn_ before each of the image names. I have tried to use concatenation but I keep getting PHP errors.
data-retina="<?php echo site_url('uploads/'.$gal->image); ?>"/>
Thanks,
Answer
Solution:
Do you mean this?
data-retina="<?php echo site_url('uploads/tn_'.$gal->image); ?>"/>
Source