• Resolved Nabil Lemsieh

    (@nlemsieh)


    I’ve encountered a translation placeholder issue in the WooCommerce translation files. The problem is related to the following text:

    #. translators: %s: regen thumbs url
    #: includes/customizer/class-wc-shop-customizer.php:591
    msgid "After publishing your changes, new image sizes may not be shown until you <a href=\"%s\" target=\"_blank\">Regenerate Thumbnails</a>."
    msgstr ""

    The placeholder %2$s is incorrectly used instead of %s in the translation file. This results in a fatal ArgumentCountError when accessing the Appearance > Customize page.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Support Shameem R. a11n

    (@shameemreza)

    Hi @nlemsieh

    I tried to reproduce the error on my testing site using Storefront and Twnety Twnty-four theme, but couldn’t. For better assistance, can you please share the steps and your site environments found in WooCommerce → Status → Get System Report?

    You could copy and paste your reply or share it via Mozilla Community Pastebin and share the link here. Feel free to redact all the private information before sending it over.

    It would be great if you could provide a video showing the issue on your end. For video, you may use https://loom.com or https://www.awesomescreenshot.com/. Please follow the instructions on that page and then paste the URL into this thread.

    In the meantime, you can run a conflict test to help you identify the cause of the issue. More info: https://woocommerce.com/document/how-to-test-for-conflicts/

    Looking forward to hearing from you!

    Thread Starter Nabil Lemsieh

    (@nlemsieh)

    Steps to reproduce the issue:

    0. Add the following code to your child theme functions.php to trigger the execution of the code at line 591 in woocommerce/includes/customizer/class-wc-shop-customizer.php:

    add_filter('woocommerce_background_image_regeneration', '__return_false');
    1. Switch your site to any language other than English from the WordPress Settings menu > General.
    2. Navigate to the WordPress Appearance menu > Customize.
    3. The error should appear.
    Plugin Support Shameem R. a11n

    (@shameemreza)

    Hi @nlemsieh

    Thanks for sharing the steps to reproduce the issue.

    I activated WP Debug mode, added your code to my theme’s functions.php, and navigated to Appearance > Customize. However, I’m still not seeing the error you mentioned. I also checked the WooCommerce error log and the server log but found nothing unusual.

    I’d be glad if you could give us more details, so that we can understand and provide a better solution.

    In the meantime, you can run a conflict test to help you identify the cause of the issue. More info: https://woocommerce.com/document/how-to-test-for-conflicts/

    I hope that helps! Let me know once you have done a conflict test!

    Thread Starter Nabil Lemsieh

    (@nlemsieh)

    Apparently, you missed the step:

    1. Switch your site to any language other than English from the WordPress Settings menu > General.

    Plugin Support Shameem R. a11n

    (@shameemreza)

    Hi @nlemsieh

    I apologize for the oversight. I tested switching the site language to a non-English language and followed the steps you provided again, but I still couldn’t replicate the error.

    I suggest proceeding with the conflict test and letting us know the results.

    Thank you for your patience and cooperation.

    Plugin Support Shameem R. a11n

    (@shameemreza)

    Hi @nlemsieh

    We’ve not heard back from you in a while, so I’m marking this thread as resolved. Hopefully, you were able to find a solution to your problem!

    If you have further questions, please feel free to open a new topic.

    Thanks!

Viewing 6 replies - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.