Home > Backend Development > PHP Tutorial > single and double quotes in php

single and double quotes in php

WBOY
Release: 2016-07-29 09:08:16
Original
869 people have browsed it
Variables inside single quotes will not be executed
Double quotes will be executed
For example
$name = 'hello';
echo "the $name";
will output the hello
And if it is a single quote
$name = 'hello';
echo 'the $name';
will output the $name

The above introduces the single and double quotation marks in PHP, including the relevant content. I hope it will be helpful to friends who are interested in PHP tutorials.

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template