Results 1 to 2 of 2
escaping the '
here is what my regular expression looks like
Code:
$file =~ s/\'/\\'/g
Is this how you escape the apostrophie...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 06-24-2003 #1Linux User
- Join Date
- Apr 2003
- Location
- TEXAS
- Posts
- 314
escaping the '
escaping the '
here is what my regular expression looks like
Is this how you escape the apostrophieCode:$file =~ s/\'/\\\'/g
The computer made me do it!! Slackware
and SUSE too Gig\'em WHOOOOP!!
\"God put me on this earth to accomplish a certain amount of tasks, At the rate I\'m going I will never die.\" (I don\'t know)
- 06-24-2003 #2Linux Guru
- Join Date
- Oct 2001
- Location
- Täby, Sweden
- Posts
- 7,578
Do you need to? This works for me:
Code:$file =~ s/'/\\'/g;


Reply With Quote
