1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

1.7 Php7 Warnings And Errors

Discussion in 'General Troubleshooting' started by valMETNG, Dec 11, 2015.

  1. shibuya246

    shibuya246 Hotaru Developer Staff Member Admin

    do you have any good thoughts on fixing this part? I just did a fresh install looking at most other things but the admin plugins page comes up with no plugins installed showing even though i can see them in the side menu
     
  2. shibuya246

    shibuya246 Hotaru Developer Staff Member Admin

    It may not be this part that is the problem actually. There are various parts throughout the code where "isset" is used to test whether an object or array has been set. That seems to be breaking in certain places but not others.
     
  3. valMETNG

    valMETNG Administrator Staff Member Admin

    Hmm... I'm not sure why it's doing that but I didn't do a base install after making the change. I don't see any problems in my admin plugin page. If you make the changes to an existing install, do you have the same problem?
     
  4. shibuya246

    shibuya246 Hotaru Developer Staff Member Admin

    looks like php7 does not like arrays of objects and when using isset against them it is showing false even though they exist
    On PluginFunctions around line 60-90, isset is used heavily to step through the in memory plugin hooks. I have changed most of these calls to use array_key_exists instead and got the admin plugin management page to load properly. I have to check for the main site and also for the loading of plugins. there may be many places where this needs changing. Did you see a similar problem on php7?
     
    Last edited: Jan 3, 2018
  5. valMETNG

    valMETNG Administrator Staff Member Admin

    Admittedly, I don't remember as it was so long ago when I looked into the problem. I do know the specific changes I made on line 163 in Hotaru.php and line 204 in /libs/Initialize.php made everything work properly. I'm wondering if you're seeing different results because your change allows for backward compatibility.
     
    shibuya246 likes this.
  6. shibuya246

    shibuya246 Hotaru Developer Staff Member Admin

    your change works and it still works on php5> as well. so lets go with it. I have it working on tamiln's site now
    thanks
     
    valMETNG likes this.

Share This Page