How to resolve WordPress error - Warning: preg_match(): Compilation failed: nothing to repeat at offset 1
In Category WordPress
Sometimes the following warning from PHP continually repeats for about 20 times and appears on top of each page.
Warning: preg_match(): Compilation failed: nothing to repeat at offset 1 in /var/www/wp-includes/classes.php on line 104
Warning: preg_match(): Compilation failed: nothing to repeat at offset 1 in /var/www/wp-includes/classes.php on line 105
These warning messages consume all the visible space in the browser making the real content not to appear. At first sight, it appears as if only errors are shown in the browser.
This can be resolved by moving back and forth from two different Permalinks structures. First login to your WordPress as administrator and go to Permalinks settings. Then change the Permalink option to default setting and apply settings. Now again change the setting back to the original and apply settings.
This should solve the problem though the cause of original problem is not known.
Thanks a bunch! I think this might have to do with Dean’s permalinks migration plugin. Toggling as you suggested fixed it tho.
This was of a great help.