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

  • SEARCH
  • Home
  • 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 6112657
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T14:46:12+00:00 2026-05-23T14:46:12+00:00

Seen many questions on same topic here, but didn’t find the answer :( I’ve

  • 0

Seen many questions on same topic here, but didn’t find the answer 🙁

I’ve got this {{Infobox[^]*?({{[^{}]*?}}[^]*?)*}} regex. Works as a charm in Javascript and here http://www.gskinner.com/RegExr/

In PHP it produces an error “Compilation failed: missing terminating ] for character class at offset 41”.

I know about delimiters, also tried putting \ before { and } — didn’t help.

{{For|the title track of the album|Master of Puppets (song)}}
{{Infobox Album <!-- See Wikipedia:WikiProject_Albums -->
| Name        = Master of Puppets
| Type        = Studio album
| Artist      = [[Metallica]]
| Cover       = Metallica - Master of Puppets.jpg
| Released    = {{Start date|1986|3|3}}
| Recorded    = September 1 – December 27, 1985 at [[Sweet Silence Studios]], [[Copenhagen]], [[Denmark]]
| Genre       = [[Thrash metal]]
| Length      = 54:41
| Label       = [[Elektra Records|Elektra]], [[Music for Nations]], [[Vertigo Records|Vertigo]]
| Producer    = Metallica, [[Flemming Rasmussen]]
| Last album  = ''[[Ride the Lightning]]''<br/>(1984)
| This album  = '''''Master of Puppets'''''<br/>(1986)
| Next album  = ''[[...And Justice for All (album)|...And Justice for All]]''<br/>(1988)
| Misc        = {{Singles
  | Name           = Master of Puppets
  | Type           = Studio
  | single 1       = [[Master of Puppets (song)|Master of Puppets]]
  | single 1 date  = July 2, 1986
  | single 2       = [[Battery (song)|Battery]]
  | single 2 date  = 1986
  | single 3       = [[Welcome Home (Sanitarium)]]
  | single 3 date  = 1986
  }}
}}
'''''Master of Puppets''''' is the third studio album by the American [[heavy metal music|heavy metal]] band [[Metallica]]. It was released on March 3, 1986 through [[Elektra Records]]. The album reached #29<ref>{{Cite news 
  | last = Pareles
  | first = Jon
  | coauthors = 
  | title = HEAVY METAL, WEIGHTY WORDS
  | work = [[The New York Times]]
  | place = USA
  | page = 8
  | language = 
  | publisher = The New York Times Company
  | date = 10 July 1988
  | url = http://www.nytimes.com/1988/07/10/magazine/heavy-metal-weighty-words.html?pagewanted=8
  | accessdate = 14 November 2010}}</ref> on the U.S. [[Billboard 200|''Billboard'' 200]] album chart and was the band's first gold record for sales of over 500,000 copies. This was done without any radio airplay or the release of a music video. The album eventually was certified 6x platinum by the [[Recording Industry Association of America|RIAA]].<ref>{{cite web|title=Gold & Platinum|url=http://riaa.com/goldandplatinumdata.php?resultpage=1&table=SEARCH_RESULTS&action=&title=Master%20of%20Puppets&artist=Metallica&format=&debutLP=&category=&sex=&releaseDate=&requestNo=&type=&level=&label=&company=&certificationDate=&awardDescription=&catalogNo=&aSex=&rec_id=&charField=&gold=&platinum=&multiPlat=&level2=&certDate=&album=&id=&after=&before=&startMonth=1&endMonth=1&startYear=1958&endYear=2008&sort=Artist&perPage=25|publisher=RIAA|accessdate=2009-12-31}}</ref> 
  • 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-23T14:46:13+00:00Added an answer on May 23, 2026 at 2:46 pm

    I think the usage of [^] is misleading/not clear, I am not sure about its meaning.

    (Because you are getting an error about a missing ], I would assume it opens a character class, the ^ is the negation of the class and the following ] does not close the class, it is its first member. But because Regexr is using it differently I think the meaning differs in the different regex engines.)

    You can try this one instead

    {{Infobox[^{]*?({{[^}]*?}}[\s\S]*?)*}}
    

    See it here on Regexr

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

Sidebar

Related Questions

I've seen many questions about this, but i've never really got the answer that
I've seen many questions like this, but i can't seem to find the answer:
I've seen many other questions on this same topic but they're not very clear
I've seen many questions on SO about .NET 3.5 advantages, but these are more
i've seen many questions on NSDateformatter and NSDate, but none could help me out.
Haven't seen many Geneva related questions yet, I have posted this question in the
I have seen many articles and Questions/Answers Regarding Lock Escalation but following things are
I have seen this same question in many forms on this site and in
I have seen many questions along these lines, and I keep seeing the same
I've seen a few questions here related to determining the similarity of files, but

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.