Good day everyone,
after creating an app in the latest Tongate I get the following errors:
Parse error: syntax error, unexpected '|', expecting '{' in /engine/tg_helpers/url_helper.php on line 100
for the function:
function nice_price(float $num, ?string $currency_symbol = null): string|float {
If I remove the function for testing, it goes on with:
Parse error: syntax error, unexpected '|', expecting ';' or '{' in /modules/trongate_pages/controllers/Trongate_pages.php on line 222
for the function:
function _make_sure_allowed(): string|false {
Did not get any search results in the help bar for these errors. Am I overseeing something, maybe.
Hopefully somebody give me a quick hint.
Have a great day :-)
Michael
Parse error in functions nice_price() and _make_sure_allowed()
3 years ago
3 years ago
#1
3 years ago
#2
Hello Michael,
I think this is where the problem is
Dan
I think this is where the problem is
Dan
3 years ago
#3
I updated to PHP 8 from PHP 7.4 to get rid of those errors, maybe you are using PHP less than PHP8?
3 years ago
#4
Thank you both. I was aware of the error but using PHP 7.4.
A nice day to all of you.
Michael
A nice day to all of you.
Michael