Jump to content

Check out our Community Blogs

Register and join over 40,000 other developers!

Recent Status Updates

View All Updates

- - - - -

What Is Escaping In A String ?

escaping string php

This topic has been archived. This means that you cannot reply to this topic.
No replies to this topic

#1 uniqueideaman


    CC Resident

  • Advanced Member
  • PipPipPipPip
  • 60 posts

Posted 26 April 2017 - 02:32 PM

What does it really mean by "escaping" in a string ?
The escape-sequence replacements are −
\n is replaced by the newline character
\r is replaced by the carriage-return character
\t is replaced by the tab character
\$ is replaced by the dollar sign itself ($)
\" is replaced by a single double-quote (")
\\ is replaced by a single backslash (\)
Does it mean "translate"/"convert"/"substitute" or does it mean "ignore this single quote and don't take it as the ending single quote" ? I thought the former but some google result links mention the latter but mostly Googling brings irrelevant results. Brings up links related to mysqli_real_escape_string.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download