php - Can I echo a variable with single quotes? -
php - Can I echo a variable with single quotes? -
can echo in single quotes variable?
example
echo 'i love $variable.';
i need because have lots of html echo too.
you must either use:
echo 'i love ' . $variable . '.';
this method appends variable string.
or use:
echo "i love $variable.";
notice double quotes used here!
php echo
Comments
Post a Comment