WordPress.org

Ready to get started?Download WordPress

Forums

WP eCommerce
[resolved] [Plugin: WP e-Commerce] Change price!!! (11 posts)

  1. mrdinh2008
    Member
    Posted 3 years ago #

    Can I change my price xx,00 to xx? Remove two zero??? Thanks

    http://wordpress.org/extend/plugins/wp-e-commerce/

  2. razrgeezer
    Member
    Posted 3 years ago #

    This is something you can do in either your presentation settings under currency or in your template files.

    I've seen this done on the icondock.com website. Which is probably the most beautiful looking WordPress e-Commerce site around.

  3. thethingfromanotherworld
    Member
    Posted 3 years ago #

    .../wp-content/plugins/wp-e-commerce/wpsc-includes/processing.functions.php

    line ~26

    $decimals = 2; // default is 2

    change to:

    $decimals = 0; // default is 2

  4. VonBlackHill
    Member
    Posted 2 years ago #

    is really sad
    this bug

    cause here in chile...
    there is no way to split a coind in 0.5 and 0.5 pesos

  5. mukesh panchal
    Member
    Posted 2 years ago #

    hyyy mrdinh2008,
    U have to change display-items-functions.php,

    <div class='wpsc_floatleft' style="width:85px;">
    <label><?php _e( 'Price', 'wpsc' ); ?>:</label>
    <input type='text' class='text' size='10' name='meta[_wpsc_price]' value='<?php echo ( isset($product_data['meta']['_wpsc_price']) ) ? number_format( (float)$product_data['meta']['_wpsc_price'], 2, '.', '' ) : 'xx.00'; ?>' />
    </div>

    to

    <div class='wpsc_floatleft' style="width:85px;">
    <label><?php _e( 'Price', 'wpsc' ); ?>:</label>
    <input type='text' class='text' size='10' name='meta[_wpsc_price]' value='<?php echo ( isset($product_data['meta']['_wpsc_price']) ) ? number_format( (float)$product_data['meta']['_wpsc_price'], 0, '.', '' ) : 'xx'; ?>' />
    </div>

    try this u get answer...

  6. tyggis
    Member
    Posted 2 years ago #

    Dont touch the core files. Its better to add this to functions.php:

    /**
    * Hide/Remove Decimal Point on Product Price by http://www.agusmu.com
    **/
    add_filter( 'wpsc_toggle_display_currency_code', 'amu_hide_decimal_point' );
    function amu_hide_decimal_point( $args ) {
    $args['display_decimal_point'] = false;
    return $args;
    }

  7. strang3r
    Member
    Posted 2 years ago #

    @tyggis

    Though I am not for your above fix but its dont even work too when I add it in theme function.php

    will you please tell me how can I replace decimal with comma? for most arabic country.. its need.

    And this comma is not working when I add it from settings. Its still showing decimal.

    This is what I am looking for something like...
    Decimal separator price: 1,000.00
    Comma separator Price: 1,000,00

    Thanks.

    WP Ecommerce V3.8.8

  8. strang3r
    Member
    Posted 2 years ago #

    I tried replacing some codes in core file in plugin but that is not even working.

  9. Justin Sainton
    Member
    Plugin Author

    Posted 2 years ago #

    Try adding this single line to your functions.php file.

    add_filter( 'wpsc_modify_decimals', '__return_zero' );

  10. strang3r
    Member
    Posted 2 years ago #

    This not working....

  11. strang3r
    Member
    Posted 2 years ago #

    its botIque theme

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic