# Advice needed for error

**URL:** https://forums.concretecms.org/t/advice-needed-for-error/3220
**Category:** Using Concrete / Help
**Created:** [June 9, 2022, 10:30am UTC](https://forums.concretecms.org/t/advice-needed-for-error/3220 "2022-06-09T10:30:07Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![sbutterworth](https://forums.concretecms.org/user_avatar/forums.concretecms.org/sbutterworth/32/1176_2.png) [@sbutterworth](https://forums.concretecms.org/u/sbutterworth)
#### Post date: [June 9, 2022, 10:30am UTC](https://forums.concretecms.org/t/advice-needed-for-error/3220/1 "2022-06-09T10:30:07Z")

</div>

good morning

i’m getting an error on the main instance of our C5 site, it says:

preg\_match(): Compilation failed: invalid range in character class at offset 4

i’ve checked the logs and the error is listed with a longer error:

9 Jun 2022, 11:05:16 Exceptions admin Exception Occurred:  
/home/xxxxxxxx/ua.xxxxxxxx.se/updates/concrete5-8.4.4/concrete/vendor/sunra/php-simple-html-dom-parser/Src/Sunra/PhpSimple/simplehtmldom\_1\_5/simple\_html\_dom.php  
:1378 preg\_match(): Compilation failed: invalid range in character class at offset 4 (2)

i’m not sure how to resolve this, so any advice would be awesome.

thanks  
🙂

---

<div class="post-metadata">

### Author: ![ConcreteOwl](https://forums.concretecms.org/user_avatar/forums.concretecms.org/concreteowl/32/5237_2.png) [@ConcreteOwl](https://forums.concretecms.org/u/ConcreteOwl)
#### Post date: [June 9, 2022, 10:52am UTC](https://forums.concretecms.org/t/advice-needed-for-error/3220/2 "2022-06-09T10:52:45Z")

</div>

@sbutterworth  
This is probably due to an upgrade of the server php.  
Line 1378 of that file looks like this

```auto
if (!preg_match("/^[\w-:]+$/", $tag)) { 
```

Try changing it to this

```auto
if (!preg_match("/^[\w\-:]+$/", $tag)) {
```

(The hyphen has been escaped with a back slash).

---

<div class="post-metadata">

### Author: ![EvanCooper](https://forums.concretecms.org/user_avatar/forums.concretecms.org/evancooper/32/4597_2.png) [@EvanCooper](https://forums.concretecms.org/u/EvanCooper)
#### Post date: [June 23, 2022, 5:45pm UTC](https://forums.concretecms.org/t/advice-needed-for-error/3220/3 "2022-06-23T17:45:17Z")

</div>

Did @ConcreteOwl 's solution do the trick for you, @sbutterworth ? If so if you can mark it as solution that’s a big help for us. Thanks!
