This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.
For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.
Help for those learning Tcl or writing their own scripts.
-
tueb
- Halfop
- Posts: 76
- Joined: Thu Oct 04, 2007 6:09 am
- Location: #quiz.de @ irc.gamesurge.net
-
Contact:
Post
by tueb »
Hi,
is there a command like stripslashes for php?
I have information stored in a mysql table and need to remove the \ from the entries.
thx,
tueb
PS: addslashes would be nice, too.^^
Last edited by
tueb on Sun Dec 07, 2008 4:34 pm, edited 1 time in total.
-
Sir_Fz
- Revered One
- Posts: 3794
- Joined: Sun Apr 27, 2003 3:10 pm
- Location: Lebanon
-
Contact:
Post
by Sir_Fz »
Code: Select all
set input [string map {\\ ""} $input]
-
nml375
- Revered One
- Posts: 2860
- Joined: Fri Aug 04, 2006 2:09 pm
Post
by nml375 »
As for addslashes, I would recommend you have a look at the mysql::escape (or mysqlescape in older versions) for proper escaping.
NML_375
-
tueb
- Halfop
- Posts: 76
- Joined: Thu Oct 04, 2007 6:09 am
- Location: #quiz.de @ irc.gamesurge.net
-
Contact:
Post
by tueb »
thx, both work =)