WooCommerce - excelling eCommerce
Edit the pricing section of a product Woocommerce (9 posts)

  1. aureliesg
    Posted 1 year ago #


    I would like to be able to edit my 'pricing' details on my product page.
    Right now, when I create my product through Woocommerce, it is set up so that the price is shown with the $ sign in front of it.


    Due to certain restrictions, I need to have a little 'asterisk' next to the price with a note at the bottom of the page, but I can't figure out how to add it.

    Of course I tried adding the * directly next to the price, but the template won't save it.
    Right now it says '$9.50' and I want it to say "$9.50*"

    Any help will be more than welcome! :)


  2. DesignerEthan
    Posted 1 year ago #

    Not sure what you mean by "the template won't save it". The best way to do this is to edit the theme. Go to your woocommerce plugin and copy the price.php (there is one in loop and single-product file) and add them to your theme. Once both price files are copied you can simply edit them.

    If for some really strange reason that does not work you could try filter the price.

    add_filter('woocommerce_price_html', 'my_price_edit');
    function my_price_edit() {
      $product = new WC_Product( get_the_ID() );
      $price = $product->price;
      echo "$" . $price . "*";

    Place that code in your functions.php and it should edit the price. Like I said the best way to do this is to actually edit the price files tho.

  3. aureliesg
    Posted 1 year ago #

    Thank you for your answer. I'm not very familiar with php, qhat do you mean by 'add them to your theme'?

    I found both price.php files but I don't really know what to do with them...

  4. DesignerEthan
    Posted 1 year ago #

    Read up on how to override woocommerce template files via your theme here. http://docs.woothemes.com/document/template-structure/

    The reason for doing this is if you simply edit the price.php when woocommerce updates your changes will be lost. That is why you have price.php in your theme to allow the plugin to update but still keep your edits safe in your own price.php.

  5. aureliesg
    Posted 1 year ago #

    Ok I did copy these files in the /mytheme/woocommerce/... (in my ftp) but for some reasons, it removed the price from my page...
    Now I just deleted these files I just added, but I still can't see my prices anymore, still - what should I do?

  6. DesignerEthan
    Posted 1 year ago #

    Did you copy the files over or remove them from the plugin and add them to your theme? They need to still be in the plugin and in your theme.

  7. aureliesg
    Posted 1 year ago #

    I just copied them. I did not remove anything...

  8. aureliesg
    Posted 1 year ago #

    Looks like all my pricing was deleted!

  9. DesignerEthan
    Posted 1 year ago #

    As in deleted from the database? This makes no sense.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WooCommerce - excelling eCommerce
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic