serbanghita / Mobile-Detect

Mobile_Detect is a lightweight PHP class for detecting mobile devices (including tablets). It uses the User-Agent string combined with specific HTTP headers to detect the mobile environment.
http://mobiledetect.net
MIT License
10.54k stars 2.68k forks source link

README correction #920

Closed htasevsk1 closed 1 year ago

htasevsk1 commented 1 year ago

Issue description In the README file it says that version 3.74.x is compatible for PHP versions >=7.3,<8.0, but in packagist it is specified that this version requires php: >=7.4.

So when I tried to require it, I got: mobiledetect/mobiledetectlib 3.74.0 requires php >=7.4 -> your php version (7.3; overridden via config.platform, actual: 7.3.31) does not satisfy that requirement.

User-Agent(s)

Suggestions In the README file it should say that version 3.74.x is compatible for PHP versions >=7.4,<8.0

epsilon-5 commented 1 year ago

Yes it does not work in php 7.3.

Parse error: syntax error, unexpected 'array' (T_ARRAY), expecting function (T_FUNCTION) or const (T_CONST) line 249: protected array $cache = [];

serbanghita commented 1 year ago

Fixed in both 4.8.x README.md and also 3.74.x

@htasevsk1 @epsilon-5 thank you! 🙇