Jump to content

strip multiple backslashes


WesleyA

Recommended Posts

Hi there

 

I'm looking for a way to strip multiple backslashes. I'm able to strip up to 7 backslashes.

 

This is my code:

$url = stripslashes($url);
$url = stripslashes($url);
$url = stripslashes($url);

You read it well, I used it 3 times. I know the backslash is a delimiter so it is necessary to use it 3 times to strip one slash. But my goal is (like with other characters) to strip all.

 

How is PHP handling this?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...