• Resolved officedigitalwrighteu

    (@officedigitalwrighteu)


    Hi,

    I get the following warning with php 8.1 and klavio Version 3.0.9
    Deprecated: Constant FILTER_SANITIZE_STRING is deprecated in \wp-content\plugins\klaviyo\includes\class-wck-options.php on line 54

    Is this already on your list? Thanks and best regards
    Benedict

Viewing 5 replies - 1 through 5 (of 5 total)
  • Yep. I’m afraid you’ve used a deprecated feature to fix the issue with the get_klaviyo_option() function…

    Please, consider replacing

    return $filter_var($option_value, FILTER_SANITIZE_STRING);

    with the following code

    $option_value = preg_replace('/\x00|<[^>]*>?/', '', $option_value);
    
    return str_replace(["'", '"'], [''', '"'], $option_value);
    Thread Starter officedigitalwrighteu

    (@officedigitalwrighteu)

    Thanks. However, I have not done anything. My question was more in the line of are you (the devs of the plugin) going to fix this soon in an upcomming patch/version?

    Sorry for the misunderstanding. With “You” I meant the plugin developers ??

    I’m also affected by this bug!

    Plugin Author klaviyo

    (@klaviyo)

    Thanks to you both for reporting this and thanks David for the fix suggestion. We will be working on getting this updated!

    Plugin Author klaviyo

    (@klaviyo)

    @officedigitalwrighteu @davefx An update has been released (version 3.0.10) which uses htmlspecialchars to escape the response. Thank you both for bringing this to our attention! If you notice any further issues, please let us know.

    • This reply was modified 1 year, 8 months ago by klaviyo.
Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Deprecated warning php 8.1’ is closed to new replies.