processwire-issues icon indicating copy to clipboard operation
processwire-issues copied to clipboard

Parse error: syntax error, unexpected '?', expecting variable (T_VARIABLE) while installing Processwire 3.0.244

Open prbt2016 opened this issue 11 months ago • 2 comments

Short description of the issue

Short description goes here.

Hello , I was in the process of manual installation of Processwire 3.0.244 on Centos 7 with PHP 7.0 , MYSQL 5.5, Apache 2.2.

However, I encountered the following error i.e :

Parse error: syntax error, unexpected '?', expecting variable (T_VARIABLE) in/{{PATH}}/{{TO}}/{{PROCWIRE}}//wire/core/Interfaces.php on line 761

But here it is mentioned that PHP 7.x versions are supported and 8.x recommended.

https://processwire.com/docs/start/install/new/

What is the exact minimum PHP requirement for installing Processwire?. I saw many min requirements mentioned . In install.php it is 5.3.8. Inside composer.json it's >=5.5. Are the minimum requirements changed?

It's working properly on PHP 7.1 (with utf8, MYISAM). Could you please update the exact requirements on official website and elsewhere required .

Also had another query. Is Processwire officially supported for MYSQL > = 5.5 , since installer mentions so as specified in screenshot below:

Please specify a MySQL 5.x+ database and user account on your server.

image

Also are there any known issues if I use MYSQL 5.5 with utf8 collate and MYISAM engine to install Processwire ? .

Kindly let me know.

Expected behavior

Processwire should be successfully installed

Actual behavior

Actual behavior goes here.

Parse error: syntax error, unexpected '?', expecting variable (T_VARIABLE) in/{{PATH}}/{{TO}}/{{PROCWIRE}}//wire/core/Interfaces.php on line 761

Optional: Screenshots/Links that demonstrate the issue

Your screenshots/links go here.

Optional: Suggestion for a possible fix

Your possible fix goes here.

Steps to reproduce the issue

  1. Visit http://example.com/procwire/install.php
  2. Enter db details.
  3. Enter admin details
  4. Click Continue

Setup/Environment

  • ProcessWire version: 3.0.244
  • (Optional) PHP version: 7.0.33
  • (Optional) MySQL version: 5.5.62

prbt2016 avatar Jan 13 '25 09:01 prbt2016

That install page needs updating because PW now needs 7.1+

The change is due to support for 8.4 - https://github.com/processwire/processwire-issues/issues/2000

adrianbj avatar Jan 13 '25 18:01 adrianbj

Thanks @prbt2016 @adrianbj I have updated the installer's min version requirement to PHP 7.1.

What is the exact minimum PHP requirement for installing Processwire?.

It depends on the version of ProcessWire, but for 3.0.244 and newer the min PHP would be 7.1, but newer would be preferable. For the previous main/master version (3.0.229) the min requirement was PHP 5.6, though technically it could even work with PHP 5.4.

Is Processwire officially supported for MYSQL > = 5.5 , since installer mentions so as specified in screenshot below:

Yes, the installer indicates 5.5+ and when it comes to version numbers, the "+" implies "and newer", i.e. "5.5+" means "5.5 and newer".

Also are there any known issues if I use MYSQL 5.5 with utf8 collate and MYISAM engine to install Processwire ? .

No issues, that's a very common setting with PW. Though utf8mb4 and InnoDB are generally preferable, at least for MySQL 5.6 and newer, but not for any stability reason.

ryancramerdesign avatar Feb 06 '25 15:02 ryancramerdesign

@prbt2016 can we close this issue?

matjazpotocnik avatar Jun 04 '25 19:06 matjazpotocnik