[horde] Horde installation with PHP7

Luis Felipe Marzagao lfbm.andamentos at gmail.com
Sun Jan 8 03:57:12 UTC 2017



Em 08/01/2017 01:51, Luis Felipe Marzagao escreveu:
>
>
>
> Em 11/09/2016 12:05, Michael J Rubinsky escreveu:
>
> Quoting Jan Schneider <jan at horde.org <https://lists.horde.org/mailman/listinfo/horde>>:
>
> >/Zitat von Melkor Lord <melkor.lord at gmail.com 
> <https://lists.horde.org/mailman/listinfo/horde>>: />//>>/On Tue, Sep 13, 2016 at 9:03 PM, Jan Schneider <jan at horde.org 
> <https://lists.horde.org/mailman/listinfo/horde>> wrote: />>//>>/If by any chance you have a quick fix for that, it would be nice: />>>//>>>>//>>>>/[ingo] PHP ERROR: Declaration of Horde_Form_Type_country::init($prompt = />>>>/NULL) should be compatible with Horde_Form_Type_enum::init($values, />>>>/$prompt />>>>/= NULL) [pid 13858 on line 0 of "/usr/share/php/Horde/Form/Type.php"] />>>>//>>>//>>>/There is no fix, this is just a warning. />>>//>>//>>/There should be a fix for that. There's obviously something wrong with 
> the />>/init() method for not supporting the same number of arguments accross 
> all />>/inheritances from Horde_Form_Type_enum. Maybe this was allowed in 
> previous />>/versions of PHP but not any more apparently. /
> If you really want a simple (and very ugly and very temporary) workaround for that,
> you could dirty edit the file /usr/share/php/Horde/Form/Type.php, rename the original
> init method and then create a new method, like this:
>
>      function initWrapped($prompt = null)
>      {
>          parent::init(Horde_Nls::getCountryISO(), $prompt);
>      }
>
>      function init($firstparam = null, $notused)
>      {
>          $this->initWrapped($firstparam);
>      }

Sorry, won't work like that. It should be:

class Horde_Form_Type_country extends Horde_Form_Type_enum {

     function initWrapped($prompt = null)
     {
         parent::init(Horde_Nls::getCountryISO(), $prompt);
     }

     function init($values = null, $prompt = null)
     {
         return $this->initWrapped($values);
     }



>
> >//>/Again, this is a warning, not a PHP error. It's about coding style. />/It doesn't influence actual behavior at all. In any PHP version. />//>>/I can dig into the code to quick-fix it myself but as you guys have the />>/full insight of your project, it would be a cleaner fix and also avoid 
> all />>/kinds of side effects. />>//>>/Currently, this error is filling up my syslog on about every page access />>/which is VERY annoying and dangerous too as it creates log noise that 
> could />>/make other errors hard to spot. />//>/Then you need to adjust your PHP error reporting level. />//>>/I really would appreciate a way to fix this ERROR, because it is 
> treated as />>/such by PHP. /
> To add to what Jan already said - even if it was something that
> *needed* to be fixed, we couldn't do so until Horde 6 since changing
> the function signatures to make those two match would be a BC break.
>
> >>/-- />>/Unix _IS_ user friendly, it's just selective about who its friends are. />//>//>//>/-- />/Jan Schneider />/The Horde Project />/http://www.horde.org/ />//>/-- />/Horde mailing list />/Frequently Asked Questions: http://horde.org/faq/ />/To unsubscribe, mail: horde-unsubscribe at lists.horde.org 
> <https://lists.horde.org/mailman/listinfo/horde> /
>
>
> -- 
> mike
> The Horde Project
> http://www.horde.org
> https://www.facebook.com/hordeproject
> https://www.twitter.com/hordeproject



More information about the horde mailing list