• Resolved oknimen

    (@oknimen)


    The error:

    PHP Deprecated: Unparenthesized a ? b : c ? d : e is deprecated. Use either (a ? b : c) ? d : e or a ? b : (c ? d : e) in /home/XXXXX/XXXXX/XXXXX/XXXXX/domain.com/wp-content/plugins/booking-system/includes/calendars/class-backend-calendar-schedule.php on line 621

    The page I need help with: [log in to see the link]

Viewing 8 replies - 1 through 8 (of 8 total)
  • Thread Starter oknimen

    (@oknimen)

    This is the line 621:

    $hours_length = count($selectedHours)-(!$settings_calendar->hours_multiple_select == ‘true’ ? true:($settings_calendar->hours_add_last_hour_to_total_price == ‘true’ && $settings_calendar->hours_interval_enabled == ‘false’ ? true:false) || ($settings_calendar->hours_multiple_select == ‘false’ ? false:($settings_calendar->hours_interval_enabled == ‘true’ ? true:false)) && ($settings_calendar->hours_multiple_select == ‘true’ ? true:false) ? 1:0);

    Same here:

    Deprecated: Unparenthesized a ? b : c ? d : e is deprecated. Use either (a ? b : c) ? d : e or a ? b : (c ? d : e) in /(…)/wp-content/plugins/booking-system/includes/calendars/class-backend-calendar-schedule.php on line 621

    Any news on how to solve this annoying message?

    Thread Starter oknimen

    (@oknimen)

    Hi… I haven’t been able to solve it yet…

    ??

    @oknimen if you want it to stop displaying, edit your php.ini so it doesn’t show deprecated messages:

    search for error_reporting, and add:

    error_reporting(E_ALL ^ E_DEPRECATED);

    It worked for me (until this plugin gets updated and/or fixed)

    Thread Starter oknimen

    (@oknimen)

    Thank you, andresabella!

    Unfortunately I am looking for how to solve the problem, and not just let the error be generated. I copied it from my error_log file, luckily it doesn’t display on the website.

    How you said, until this plugin gets updated and/or fixed, your method could serve me… do you know if this issue have a high risk or any risk or to my site?

    Thank you very much!

    No, no risk at all. It’s just a “hey, don’t show “deprecated” messages”.

    BTW, as long as people told me (and I just copypaste):

    “” It’s a deprecated warning, not an error. It’s telling you to make sure that the developer knows that there is a deprecated language construct in the code that needs to be solved before it will run in PHP 8.0. “”

    Plugin Author DOTonPAPER

    (@dotonpaper)

    Hello,

    We will investigate this issue and will add a fix in future updates for these warnings.

    Until then please send an email to [email protected] and we will fix them for you.

    Thank you!

    Thread Starter oknimen

    (@oknimen)

    Thank you @andresabella for your intentions to help me and @dotonpaper for the response!

    I send you a mail yet.

    Sincerily, I hope that this case can be helpful for this plugin development.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Help: Unparenthesized `a ? b : c ? d : e` is deprecated’ is closed to new replies.