• Hello! Thanks for your great work on this plugin. It’s very simple and does exactly what is needed.

    Could you add the option to change the placeholder text on the plugin settings page? It would be very helpful to be able to change the current “Ex. $100”

    Thanks!

Viewing 8 replies - 1 through 8 (of 8 total)
  • Agree!

    Lidia

    (@lydiamunoz)

    I would like to know how i can do this… I tried with loco translate but i can’t.
    Thank you!

    You can change it manually if you want. Open the woo-donations.php file from the wp-content/plugins/woo-donations folder.

    Around lines 114, 152 and 170 you will find along the line: (Change on each)
    class=”wdgk_donation” placeholder=”Ex. ‘.get_woocommerce_currency_symbol().’200″>

    If you want to keep the currency symbol, then just change the Ex. to your needs and the 200 to the value you want. If no currency symbol you can just have placeholder=”text here”> and remove the ‘.get_woocomer… bit

    Lidia

    (@lydiamunoz)

    Hi!
    Thank you!
    But if i edit code in your plugin a?os you update it in the future, i will lost the changes, isn’t it?

    Hi,
    Its not my plugin, but yes you are correct if the owner does update it will over write. Make sure you keep a copy of what you change, then you can make the changes again if updated…. but the plugin has not been updated in 11 months.

    Hello all, I found a way to do this via jQuery without editing plugin-files

    $('.wdgk_donation').attr('placeholder', '$' );

    I was able to just place a dollar sign as the placeholder. You could technically replace my dollar sign with any text string you want.

    Hope this helps!

    • This reply was modified 4 years, 8 months ago by Ben Kaminski.

    @tzhben

    Could you please give me details for how to add the jquery you added.

    thanks

    Here’s how I accomplished this without jquery or PHP:

    1. Install the Insert Headers and Footers plugin, and activate it.

    2. Go to Settings > Insert Headers and Footers, and paste this into the “Scripts in Footer” box:

    
    <script type="text/javascript">
      document.getElementsByClassName('wdgk_donation')[0].placeholder = "";
    </script>
    

    Put whatever you want between the double quotes or just leave it blank ??

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Change Placeholder Text?’ is closed to new replies.