Invision Community 4: SEO, prepare for v5 and dormant account notifications Matt November 11, 2024Nov 11
Posted July 27, 20222 yr I have a fully patched v4.7.0 running. I switched my server from PHP 7.4 to 8.0. When I did that, there was a 500 error in the browser. When I looked at the server logs, I saw the following repeated several times: [27-Jul-2022 15:07:10 UTC] PHP Fatal error: Unparenthesized `a ? b : c ? d : e` is not supported. Use either `(a ? b : c) ? d : e` or `a ? b : (c ? d : e)` in /home/realtree/forums.realtree.com/public_html/system/Theme/Theme.php(885) : eval()'d code on line 525 I have another fully patched v4.7.0 running on the same server. That site had no issues when I switched to PHP 8.0. Is this some type of theme problem? I compared the Theme.php file in both sites, and they're identical.
July 27, 20222 yr Are you running a custom theme? If so… try switching back to a default theme and see if the problem persists. It may be an issue with your theme itself.
July 27, 20222 yr Community Expert As Randy mentioned, check your themes and third party applications/plugins by switching to an unmodified theme and disabling third party applications/plugins.
October 19, 20222 yr Author So, I upgraded to 4.7.3 this morning and tried the switch to PHP 8.0 again. This time I'm getting a different error. Can you confirm this is related to a theme? Maybe a global template? [19-Oct-2022 13:39:35 UTC] PHP Fatal error: Unparenthesized `a ? b : c ? d : e` is not supported. Use either `(a ? b : c) ? d : e` or `a ? b : (c ? d : e)` in /home/realtree/forums.realtree.com/public_html/uploads/template_1_ad9ae6e9ced8695954ac11f917afdfac_global.php on line 526 The PHP8 Compatibility Scanner on the support page isn't showing any issues. Any suggestions for my developer to troubleshoot this?
October 19, 20222 yr Community Expert 2 minutes ago, Clint Davis said: So, I upgraded to 4.7.3 this morning and tried the switch to PHP 8.0 again. This time I'm getting a different error. Can you confirm this is related to a theme? Maybe a global template? [19-Oct-2022 13:39:35 UTC] PHP Fatal error: Unparenthesized `a ? b : c ? d : e` is not supported. Use either `(a ? b : c) ? d : e` or `a ? b : (c ? d : e)` in /home/realtree/forums.realtree.com/public_html/uploads/template_1_ad9ae6e9ced8695954ac11f917afdfac_global.php on line 526 The PHP8 Compatibility Scanner on the support page isn't showing any issues. Any suggestions for my developer to troubleshoot this? Yes, this shows that your theme is out of date and needs to be updated to include template changes that were introduced in newer versions. Have a look at this guide, the second part "Comparing within the AdminCP" will be the most useful since you may not know which version your theme was originally created in.
October 20, 20222 yr Author Today, I reverted all my custom templates in my theme, and I'm still getting the same error. Is there any way to force it to rebuild the template_1_ad9ae6e9ced8695954ac11f917afdfac_global.php file based on the current templates?
October 20, 20222 yr Community Expert We would need to look further into this for you, however the access details on file appear to be incorrect or missing. Could you please update these details by visiting your client area, selecting the relevant purchase, then clicking "Review/Update Access Information" under the "Stored Access Information" section. We look forward to further assisting you.
October 20, 20222 yr Community Expert Could you please clarify where you're encountering this error? When viewing your community, everything seems OK. It is also noting that your Benelli theme is still customized.
October 20, 20222 yr Author I think we've resolved the issue. We created a new theme and applied our customizations to the templates once more. Seems to be working.
October 30, 20222 yr On 10/20/2022 at 10:36 AM, Clint Davis said: I think we've resolved the issue. We created a new theme and applied our customizations to the templates once more. Seems to be working. Can you clarify how do you fix this issue?
October 31, 20222 yr Community Expert 11 hours ago, Cach Doan said: Can you clarify how do you fix this issue? Im not sure I understand what question you are asking there, as what you quoted is what they did there. They created a new theme in the admin CP, then reapplied any customisations they had. To clarify, this will have resolved the issue, as there will have been changes in the theme that were breaking changes in PHP8
October 31, 20222 yr On 10/20/2022 at 10:36 AM, Clint Davis said: I think we've resolved the issue. We created a new theme and applied our customizations to the templates once more. Seems to be working. Same type of issues on my side. I suspect the new version of IPB that hides some css files is not showing a few we edited. I may go the same route as you to start clean.
October 31, 20222 yr Community Expert 20 minutes ago, Fast Lane! said: Same type of issues on my side. I suspect the new version of IPB that hides some css files is not showing a few we edited. I may go the same route as you to start clean. As mentioned on the other ticket you have. We would need to know which theme, and we can take a look for you
January 22, 20232 yr I have resolved my issued by disabling one of the plugins I had. Now I need to find a replacement. It was called "Hide Content Until User Replies"
January 23, 20232 yr Community Expert Glad to hear you found what was causing your problem there, and hope you find what you need in terms of replacement