Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6116219
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T15:10:53+00:00 2026-05-23T15:10:53+00:00

How to remove all text between BBCode Quotation (including BBCode itself): [quote date=2011-07-02 14:43:53

  • 0

How to remove all text between BBCode Quotation (including BBCode itself):

[quote date=2011-07-02 14:43:53 user=test link=1]blabla[/quote]

I must add that between tags can be text with HTML tags for formating.
My current attempt looks like:

Regex regex = new Regex(@"[quote+].+?[/\+quote]");

Well it’s almost working.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T15:10:54+00:00Added an answer on May 23, 2026 at 3:10 pm

    Since your BBCode blocks contains attributes, a simple + won’t suffice to cover everything. + means to repeat the specified range of characters, in this case e.

    On the top of my head, I’d try something like this:

     \[quote([^\[]*)\](.*?)\[\/quote\]
    

    Please bear in mind that I have not tested this for C#, where the syntax might be different depending on the interpreter. Also note that I’ve added selection groups so that you’d be able to examine the result of each expression. As @Howard answered, [ and ] are reserved symbols and consequently needs to be escaped.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to remove all the text between (and including) two strings in all
How can one remove all text, but leave the structure intact? for example: <animals>
I have a string. How do I remove all text after a certain character?
I have string like this: G:\Projects\TestApp\TestWeb\Files\Upload\file.jpg How can I remove all text before Files
for example : I want to remove all highlighted tags alt text http://shup.com/Shup/299976/110220132930-My-Desktop.png
A followup question to Get all text between tags with preg_match_all() or better function?
Anyone know how to remove white space between strings for all browsers? This works
I am come up with a regex to grab all text between 2 HTML
I need to remove all '\n' between '<' and '>' in html file with
<p>Text</p> <ul> <li>One</li> </ul> <p>Text 2</p> How do i remove the vertical space between

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.