MyBB Community Forums

Full Version: Warning [2] preg_replace() [function.preg-replace]: Compilation failed: unmatched par
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello, I am getting this error when attempting to create a post or view posts on my forum:
The following warnings occurred:
Warning [2] preg_replace() [function.preg-replace]: Compilation failed: unmatched parentheses at offset 18 - Line: 346 - File: inc/class_parser.php PHP 5.2.14 (Linux)
File 	Line 	Function
[PHP] 	  	errorHandler->error
/inc/class_parser.php 	346 	preg_replace
/inc/class_parser.php 	156 	postParser->parse_mycode
/inc/functions_post.php 	570 	postParser->parse_message
/showthread.php 	949 	build_postbit

My forum that this is occurring on is: http://how-to-sing.net/forum/thread-1.html

Currently all plugins are disabled... thanks for the help!

Sarosia
You either didn't upload the file completely or have manually modified it. In your AdminCP go to Tools & Maint.->File Verification and check your files out. But most likely if you ftp a new copy of inc/class_parser.php to your server it will fix this issue.
Thanks for the response, but uploading the new class_parser.php did nothing and File Verification didn't display anything out of the ordinary.
Do you have any MyCodes set? Try removing them.
(2011-01-11, 07:18 AM)- G33K - Wrote: [ -> ]Do you have any MyCodes set? Try removing them.

An unmatched parens inside a custom MyCode will do this? Interesting if so Smile
(2011-01-11, 07:19 PM)Dylan M. Wrote: [ -> ]
(2011-01-11, 07:18 AM)- G33K - Wrote: [ -> ]Do you have any MyCodes set? Try removing them.

An unmatched parens inside a custom MyCode will do this? Interesting if so Smile

The line # in the error is where the MyCode regex is happening, maybe its some messed up MyCode, just a hunch Wink
(2011-01-11, 07:22 PM)- G33K - Wrote: [ -> ]
(2011-01-11, 07:19 PM)Dylan M. Wrote: [ -> ]
(2011-01-11, 07:18 AM)- G33K - Wrote: [ -> ]Do you have any MyCodes set? Try removing them.

An unmatched parens inside a custom MyCode will do this? Interesting if so Smile

The line # in the error is where the MyCode regex is happening, maybe its some messed up MyCode, just a hunch Wink

A good hunch though Wink
Disabling the MyCode solved it! Thanks guys... don't know why this happened as it was working fine before. Had the "progress bar" MyCode in use which can be found here.

Solved Topic