E
E
estry2018-02-27 13:30:55
C++ / C#
estry, 2018-02-27 13:30:55

How to remove \ character using C# regular expression?

Hey! How to remove \ from url with regex? For example from this address, https:\/\/pp.userapi.com\/c841226\/v841226735\/72c15\/CrqCyt7DhCA.jpg
And the second question. How to regularly remove HTML tags? Such as
others.
Thank you in advance!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
E
Explida, 2018-02-27
@estry

I think something like this, but without the regular season (it just doesn't make sense to me)

string end = string.Empty;
            string inputHttp = @"https:\/\/pp.userapi.com\/c841226\/v841226735\/72c15\/CrqCyt7DhCA.jpg";
            var result = inputHttp.Split('\\');
            foreach (var tempFor in result)
            {
                end += tempFor; 
            }

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question