Home › Forums › Theme support › Kingpin PHP 7.0 Compatibility Errors
This topic contains 11 replies, has 2 voices, and was last updated by 7Theme Support 6 years, 10 months ago.
-
AuthorPosts
-
I have 5 add-on WordPress websites on my server and all sites work well with PHP 7.1 but the only website that is using your Kingpin theme will only work as we get errors. It will work using PHP 5.6. I need to have it work using PHP 7.0 or 7.1. Below are the errors doing a compatibility test. The them version I am using is Version: 1.02. I see in a post in your forum you mention that it is a php.ini file being the issue. If this is the case please give me the exact information to add to a php.ini file. My hosting company said this should not be the problem.
FILE: /home/ixy6urg/public_html/newdanvillebowl/wp-content/themes/kingpin/header.php
————————————————————————————
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
————————————————————————————
1 | WARNING | File has mixed line endings; this may cause incorrect results
————————————————————————————FILE: /home/ixy6urg/public_html/newdanvillebowl/wp-content/themes/kingpin/7league/widgets.php
————————————————————————————————————
FOUND 0 ERRORS AND 18 WARNINGS AFFECTING 18 LINES
————————————————————————————————————
111 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
189 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
243 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
335 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
404 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
464 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
525 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
577 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
633 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
678 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
724 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
770 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
863 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
953 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
1043 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
1095 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
1146 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
1236 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
————————————————————————————————————FILE: /home/ixy6urg/public_html/newdanvillebowl/wp-content/themes/kingpin/7league/autoimporter.php
—————————————————————————————————————————————————————————–
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
—————————————————————————————————————————————————————————–
71 | WARNING | Use of deprecated PHP4 style class constructor is not supported since PHP 7.
752 | ERROR | Indirect access to variables, properties and methods will be evaluated strictly in left-to-right order since PHP 7.0. Use curly braces to remove ambiguity.
—————————————————————————————————————————————————————————–FILE: /home/ixy6urg/public_html/newdanvillebowl/wp-content/themes/kingpin/7league/css/customcss.php
————————————————————————————————————————————————————————–
FOUND 2 ERRORS AFFECTING 2 LINES
————————————————————————————————————————————————————————–
25 | ERROR | Indirect access to variables, properties and methods will be evaluated strictly in left-to-right order since PHP 7.0. Use curly braces to remove ambiguity.
29 | ERROR | Indirect access to variables, properties and methods will be evaluated strictly in left-to-right order since PHP 7.0. Use curly braces to remove ambiguity.
————————————————————————————————————————————————————————–FILE: /home/ixy6urg/public_html/newdanvillebowl/wp-content/themes/kingpin/7league/anonym.php
———————————————————————————————————-
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
———————————————————————————————————-
39 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
———————————————————————————————————-FILE: /home/ixy6urg/public_html/newdanvillebowl/wp-content/themes/kingpin/7league/7league_functions.php
————————————————————————————————————
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
————————————————————————————————————
3315 | WARNING | Function create_function() is deprecated since PHP 7.2; Use an anonymous function instead
————————————————————————————————————Hi,
what version of the theme do you use? Because we made an update specially for PHP7 (Version 1.01), and the most recent version is 1.02. You can download the most recent version of the theme always in your account on 7theme.net
I do have version 1.02 installed as I mentioned when I submitted this ticket as you can see above.
Ok, that’s really strange, we checked the files, i.e. “widgets.php”, and it does not contain the function “create_function()” (see error log in your first post). If you want, you can send us ( info @ 7theme . net ) a link + login for your website, then we can take a look at the files.
I see in a post in your forum you mention that it is a php.ini file being the issue. If this is the case please give me the exact information to add to a php.ini file. My hosting company said this should not be the problem.
Sorry, forgot to answer this question from your first post. If you want, you can add this in your index.php file in the root of your website (right after the “<?php” line ):
ini_set('display_errors', 0); ini_set('display_startup_errors', 0); error_reporting(0);
This is the easiest way if you know how to edit your files. You can write this also your hosting provider, for the PHP.ini file it’s nearly the same, they will know what to do
Here is the administrator login per your request. Let me know what you find out and do I still need to add the ini lines to my index.php? I will wait till you respond on what you found.
http://www.danvillebowl.com/wp-admin
User: ***
Pass: ****Hello,
I have the Kingpin theme version 1.02 and it is still no passing the PHP 7.0 and the PHP 7.1 compatibility test. The following is what is showing up as a problem. Can you please help me with this problem?
FILE: /home/ixy6urg/public_html/newdanvillebowl/wp-content/themes/kingpin/header.php
————————————————————————————
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
————————————————————————————
1 | WARNING | File has mixed line endings; this may cause incorrect results
————————————————————————————FILE: /home/ixy6urg/public_html/newdanvillebowl/wp-content/themes/kingpin/7league/autoimporter.php
—————————————————————————————————————————————————————————–
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
—————————————————————————————————————————————————————————–
71 | WARNING | Use of deprecated PHP4 style class constructor is not supported since PHP 7.
752 | ERROR | Indirect access to variables, properties and methods will be evaluated strictly in left-to-right order since PHP 7.0. Use curly braces to remove ambiguity.
—————————————————————————————————————————————————————————–The first thing is only a warning, we checked the file manually and there is no problem, we checked it several times. Maybe there is an error in the script you use.
The second message for a file we included to do the one-click demo content import, but also here is no problem, because the part with the error we don’t use in the theme (it’s an open source script, that’s why the part with the error is included). We will remove it in one of the next update. The shown error will not affect your website or the theme, you can use it with PHP 7 without any problem, we tested it already!
When I changed it to PHP 7.0 the error shows up on the website. I couldn’t copy the text so I took a screen shot and below is a link so you can see the problem.
http://www.danvillebowl.com/wp-content/uploads/2018/05/Capture.png
If you are looking at the website and need me to switch the server to PHP 7.0 let me know via Skype. My Skype name is “robbcapp”
Hi,
please take again a look at your screenshot, that’s only a warning and a completely other files, it’s not the file(s) from your test. A warning is only a warning, not an error. Those messages are only for developers and should never be visible on public websites because a hacker can provoke such kind of messages and find weak points on your website. You should contact your hosting provider and ask to remove “PHP error messages and warnings” in the php.ini file. Again: that’s nothing for public websites!
If you want, you can send us (please via mail to info @ 7theme . net ) a mail, then we can add a workaround on your website to remove the error message.
Those warnings were on the front end of the live website on top of the header and was visible to all visitors to the website so yes the error warnings need to be removed. I will send an email to info@ as well.
Thanks,
Robb
Hi Robb,
wrote you already a mail…
-
AuthorPosts
You must be logged in to reply to this topic.