• Resolved pumka

    (@pumka)


    After updating to 1.6.0, we noticed that “action” column displays the text “Array” instead of add-to-cart button. I already found that it is caused by this code at wp-content/plugins/product-variant-table-for-woocommerce/inc/table-parts/content-tbody.php:354:

    elseif( strtolower( $key2 ) == __("action", "product-variant-table-for-woocommerce") ){

    It should actually say “Action”, starting from the upper case:

    elseif( strtolower( $key2 ) == __("Action", "product-variant-table-for-woocommerce") ){

    because it is assigned so at wp-content/plugins/product-variant-table-for-woocommerce/inc/table-parts/content-tbody.php:229

    $key1_title = __('Action', 'product-variant-table-for-woocommerce');

    This happens if the site’s locale is not English (Swedish in our case), so the string “Action” is getting translated but the string “action” not because there is no translation for it.

    Could you please fix this? Thanks in advance!

    • This topic was modified 6 months, 3 weeks ago by pumka.
Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author WPXtension

    (@wpxteam)

    Hi,

    Thank you for sharing your thoughts. I wanted to clarify whether both “action” and “Action” were translated correctly. Kindly review the screencast I’ve shared here for further details: https://www.loom.com/share/9baa69a7a09f44f09fb3bb2a8bc2ffa1

    We have tested the issue on our end and were unable to replicate it. In the latest version (1.6.0), we have not made any changes to the code affecting the lines you mentioned. Therefore, if the functionality works correctly in version 1.5.4, it should also work in 1.6.0.

    Regarding the following code line:

    elseif( strtolower( $key2 ) == __("Action", "product-variant-table-for-woocommerce") ){

    The $key2 variable is passed through a function to convert the string to lowercase. As a result, it will not conditionally match “Action” as expected.

    I encourage you to follow the steps in the screencast, as it should resolve the issue. However, if you find anything I may have missed or if you have additional concerns, please don’t hesitate to share.

    Best Regards

    Plugin Author WPXtension

    (@wpxteam)

    Hi,

    I hope you are doing well today.

    We have adjusted the condition in our 1.6.2 version. Please update to the latest release 1.6.3.

    Can you please confirm, if you are still getting this issue or not?

    Hope to hear from you soon.

    Best Regards

    Thread Starter pumka

    (@pumka)

    Sorry about the later reply. Looks like the update fixed the “Array” string. It broke a compatibility with the 1.6.0 “pro” counterpart of the plugin though and that’s why I hesitated to install the update. I’m asking my client to update the pro plugin to check if it resolves the compatibility issue.

    • This reply was modified 4 months, 2 weeks ago by pumka.
    Plugin Author WPXtension

    (@wpxteam)

    Hi,

    Sure, please let us know your feedback. We will wait for your reply. 🙂

    Best Regards

    Thread Starter pumka

    (@pumka)

    Yes, it works fine now. Thanks!

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