i am trying to print " in echo statement.
i can't get any method other than
<?php
echo " " ";
?>
which is definitely wrong.
help me to find a way out of it.
any help is appreciated.
i am trying to print " in echo statement.
i can't get any method other than
<?php
echo " " ";
?>
which is definitely wrong.
help me to find a way out of it.
any help is appreciated.
Jump to PostYou need to escape the double quote with a backslash:
<?php
echo " \" ";
?>
try using single qoute for the double quotes and double quoutes for the single quotes. Otherwise, yo can escape it. Another alternative is to use heredoc for a longer string., but for your situation something like this will do..
<?php
echo '"';
echo "' '";
?>
You need to escape the double quote with a backslash:
<?php
echo " \" ";
?>
thanks for your response.
i will keep that in mindand use it in future.
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.