• Resolved adam1414

    (@adam1414)


    I have an error log filled with thousands of lines of the same error:

    [28-Jun-2020 17:09:49 UTC] PHP Notice: Undefined variable: m2 in /var/www/vhosts/mydomain.com/httpdocs/wp-content/plugins/w3-total-cache/UserExperience_LazyLoad_Mutator.php on line 135

    I’ve tried looking online for anything similar without luck. Can anyone point in the right direction??

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Contributor Marko Vasiljevic

    (@vmarko)

    Hello @adam1414

    I am sorry about the issue you are experiencing and I am happy to assist you with this.
    The issue you are referring to was fixed in 0.14.3 release as it was reported in our GitHub repostirory.
    The issue was a typo in /w3-total-cache/UserExperience_LazyLoad_Mutator.php on line 135
    it was:
    $url = ( !empty( $m[4] ) ? $m[4] : ( ( !empty( $m[3] ) ? $m[3] : $m2 ) ) );
    and fixed with:
    $url = ( !empty( $m[4] ) ? $m[4] : ( ( !empty( $m[3] ) ? $m[3] : $[m2] ) ) );
    Please update the plugin to the latest 0.14.3 release to fix the issue.
    Thanks!

    Thread Starter adam1414

    (@adam1414)

    Thank you, Marko, for the quick response. This was a fairly new install – I should have looked for an update first to see if that fixed it.

    On a side note – it looks like the code sample from above still has a typo – I may be wrong and I’m sure this is just a sample for my sake and not from the actual code, but it looks like it should be m[2] and it is written as [m2] above. Just in case anyone else is referencing it.

    Thanks again!

    • This reply was modified 5 years, 10 months ago by adam1414.
    Plugin Contributor Marko Vasiljevic

    (@vmarko)

    Hello @adam1414

    Yes, sorry this was actually my typo 🙂
    it should be:
    $url = ( !empty( $m[4] ) ? $m[4] : ( ( !empty( $m[3] ) ? $m[3] : $m[2] ) ) );
    SOrry for the typo again and Thank you!

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Undefined Variable: m2 in experience_lazyload_mutator.php’ is closed to new replies.