Curious,
I know what the piece of text "\n" does; It makes a new line in a string of text.
But I've seen similar things, such as "\r" or "\f" and more.
What are these are these things really called, and are there more of them?
\r is a carriage return... in windows \r\n takes you to the begining of the next line... in linux \n suffices to do both...
as for some others... I know one is a tab, another tells the system speaker to go 'ding'... one's a backspace... i don't remember them all... google it, I'm sure you'll find something
Thanks, but Google strips out any slashes. 🙁 That's why I came here. 😃
The ones PHP recognises are also given in the manual (where you will also find out what they're called, and hence have more ammunition for Google).
http://www-ccs.ucsd.edu/c/charset.html
[b]Character Meaning[/b] space leave blank space BEL signal an alert (BELl) BS go back one position (BackSpace) FF go to top of page (Form Feed) NL go to start of next line (NewLine) CR go to start of this line (Carriage Return) HT go to next Horizontal Tab stop VT go to next Vertical Tab stop [b]Character Escape Sequence[/b] " \" ' \' ? \? \ \\ BEL \a BS \b FF \f NL \n CR \r HT \t VT \v
Ah, I see.
Thank you both! 😃
i think that PHP only reconizes: \r,\n, and \t . you can escape any character but ive only ever used anything but those and \", \', for ereg([_]?.*) functions.
Don't forget: "new line" on Macs (older ones at least) is \r 🙂
Originally posted by Moonglobe i think that PHP only reconizes: \r,\n, and \t . you can escape any character but ive only ever used anything but those and \", \', for ereg([_]?.*) functions.
well, you need to read the PHP manual too
Originally posted by laserlight well, you need to read the PHP manual too
yup, i probably do, but i know for a fact that \a and \b arn't supported...... i dont think \f is either. as for \v i forget bt then again.......
Originally posted by Moonglobe i think
:mad: and of course i did forget about \ .... but o well we all make mistakes!