• Resolved niznet

    (@niznet)


    Hi,

    There’s an issue with how the call_user_func_array is implemented within the plugin, actually in PHP 8,
    $params = call_user_func_array('array_merge', $this->get_editor_options());
    will break, and most of the fixes by wrapped with,
    array_values($this->get_editor_options()).

    It was fixed by that trick but not sure it was okay to remove array keys as I don’t check plugin javascript. For now, I downgraded my PHP to 7.4.

    • This topic was modified 2 years, 4 months ago by niznet.
    • This topic was modified 2 years, 4 months ago by niznet.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Ali Khallad

    (@alikhallad)

    Hello, thank you so much for reporting this!

    We have fixed the PHP 8 compatibility issues in the latest release 1.2.6

    Please don’t hesitate to contact us if you notice more issues.

    Thanks,
    Ali

    Thread Starter niznet

    (@niznet)

    Thanks for the quick update, so far been pleasant, and I’m planning to continue using your plugin for my others clients.

    Actually, there is some inconsistent prefix for hook names when I tried to search for available hooks.

    I found filter & action names with ‘megaforms_, ‘mf_ and ‘mega_form
    I assume ‘mf_ here is the correct one as I have seen them more than others, it would be better if we have one standard as I’m afraid to mistype them.

    Plugin Author Ali Khallad

    (@alikhallad)

    Hello,

    Thanks, we appreciate the kind words and happy that you like our plugin.

    Yes, we were using ‘megaforms_’ and ‘mega_form’ prefixes at the begining for the initial version that was very small and simple but decided to use ‘mf_’ later and didn’t think about changing the existing prefixes. However, since you mentioned this point, I’ll make sure to release a new update shortly that tackles this point.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘PHP8: call_user_func_array break because of named parameters’ is closed to new replies.