Tools, FAQ, Tutorials:
Escape Sequences in Single-Quoted Strings in PHP
How Many Escape Sequences Are Recognized in Single-Quoted Strings?
✍: FYIcenter.com
There are two special characters you need to escape in a single-quote string: the single quote (') and the back slash (\). Here is a PHP script example of single-quoted strings:
<?php echo 'Hello world!'; echo 'It\'s Friday!'; echo '\\ represents an operator.'; ?>
This script will print:
Hello world!It's Friday!\ represents an operator.
⇒ "new line" Character in Single-Quoted Strings in PHP
⇐ Understanding PHP String Literals and Operations
2016-10-13, ∼2299🔥, 0💬
Popular Posts:
How to use urllib.parse.urlencode() function to encode HTTP POST data? My form data has special char...
How to start Visual Studio Command Prompt? I have Visual Studio 2017 Community version with Visual C...
How To Get the Minimum or Maximum Value of an Array in PHP? If you want to get the minimum or maximu...
dev.FYIcenter.com is a Website for software developer looking for software development technologies,...
How To Read the Entire File into a Single String in PHP? If you have a file, and you want to read th...