Forum Replies Created

Viewing 4 posts - 1 through 4 (of 4 total)
  • Avatar: relentlessmike
    relentlessmike
    Participant

    Thanks for the support! My topic “The logo is missing form the header” has been successfully resolved.

    Avatar: relentlessmike
    relentlessmike
    Participant

    One last question. How do we make the fonts margin left on the slider item? On our home page the slide fonts margin to the left except on the mobile version.

    Avatar: relentlessmike
    relentlessmike
    Participant

    Thank you!

    Avatar: relentlessmike
    relentlessmike
    Participant

    Hello there-

    I have been working on the same thing for a few days now. I have used a very similar line of code that is giving me a field to enter the UPC when entering a new product, but I cannot get it to reflect properly on the front end. Even when I use the same line of code as above I still get a field that reflects the UPC as a price “$123,456,789.00″.

    I too need it to reflect in the custom fields for csv export.

    Here is what I have been playing with so far. It worked great for adding my MSRP.

    add_action( ‘woocommerce_product_options_pricing’, ‘wc_upc_product_field’ );
    function wc_upc_product_field() {
    woocommerce_wp_text_input( array( ‘id’ => ‘UPC’, ‘class’ => ‘wc_input_price short’, ‘label’ => __( ‘UPC’, ‘woocommerce’ ) . ” ) );
    }
    add_action( ‘save_post’, ‘wc_upc_save_product’ );
    function wc_upc_save_product( $product_id ) {
    // If this is a auto save do nothing, we only save when update button is clicked
    if ( defined( ‘DOING_AUTOSAVE’ ) && DOING_AUTOSAVE )
    return;
    if ( isset( $_POST[‘UPC’] ) ) {
    if ( is_numeric( $_POST[‘UPC’] ) )
    update_post_meta( $product_id, ‘UPC’, $_POST[‘UPC’] );
    } else delete_post_meta( $product_id, ‘UPC’ );
    }
    add_action( ‘woocommerce_single_product_summary’, ‘wc_upc_show’, 5 );
    function wc_upc_show() {
    global $product;
    // Do not show this on variable products
    if ( $product->product_type <> ‘variable’ ) {
    $upc = get_post_meta( $product->id, ‘UPC’, true );
    echo ‘<div class=”woocommerce_upc”>’;
    _e( ‘UPC: ‘, ‘woocommerce’ );
    echo ‘<span class=”woocommerce-upc-price”>’ . woocommerce_price( $upc ) . ‘</span>’;
    echo ‘</div>’;
    }
    }

Viewing 4 posts - 1 through 4 (of 4 total)