Viewing 7 posts - 1 through 7 (of 7 total)
  • #148944
    ryansharpley
    Member
    Post count: 17

    Hi all

    Couple of newbie questions

    Q1
    Ive read through the custom CSS to hide sku/comments etc – though I can’t see how to hide tags – Ive put this in the CSS though TAGS still show? What am I doing wrong?

    .need-help,.leave-feedback,.sku_wrapper,.tags-link-wrap{display:none !important}

    Q2
    How can I expand the product description text by default?

    Q3
    How can I change the ADD TO SHOPPING BAG to just ADD TO CART on the product?

    Thanks in advance
    Ryan

    #148953
    ryansharpley
    Member
    Post count: 17

    ignore Q2 – found this – div#product-description{height:auto;} – which works!

    other questions would be much appreciated any thoughts

    #148958
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,
    1- Please use this custom css code:-

    div.product_meta{
    display:none !important;
    }
    

    2- Please paste this code at functions.php of child theme.

    function sf_text_strings( $translated_text, $text, $domain ) {
    switch ( $translated_text ) {
    case 'Add to shopping bag' :
    $translated_text = __( 'Add to Cart', 'woocommerce' );
    break;
    }
    return $translated_text;
    }
    add_filter( 'gettext', 'sf_text_strings', 20, 3 );

    Thanks
    Mohammad

    #149242
    ryansharpley
    Member
    Post count: 17

    Thanks Mohammad

    The first question works well (hide sku)

    Though could you explain the child theme – I have installed and activated the neighbourhood-child theme and looked for a functions.php – there wasn’t one, so I created a file in the directory and posted the code – this resulted in syntax errors, so I encapsulated it in <?php ?> but it still failed.

    Please let me know what the contents for the functions.php and I will amend

    <?php
    function sf_text_strings( $translated_text, $text, $domain ) {
    switch ( $translated_text ) {
    case ‘Add to shopping bag’ :
    $translated_text = __( ‘Add to Cart’, ‘woocommerce’ );
    break;
    }
    return $translated_text;
    }
    add_filter( ‘gettext’, ‘sf_text_strings’, 20, 3 );
    ?>

    Thanks

    #149273
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,
    Please provide me wordpress admin login detail to check and resolve the issue. You can change this text through .po , .mo language translation files too.
    Thanks
    Mohammad

    #149380
    ryansharpley
    Member
    Post count: 17
    This reply has been marked as private.
    #149411
    Mohammad – SUPPORT
    Moderator
    Post count: 27441

    Hi,
    I have resolved this issue through this code.

    <?php
    function sf_text_strings( $translated_text, $text, $domain ) {
    $translated_text = strtolower($translated_text);
    switch ( $translated_text ) {
    case 'add to shopping bag' :
    $translated_text = __( 'Add to Cart', 'woocommerce' );
    break;
    }
    return $translated_text;
    }
    add_filter( 'gettext', 'sf_text_strings', 20, 3 );
    ?>

    Thanks
    MOHAMMAD

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

You must be logged in and have valid license to reply to this topic.

License required for one of the following items
Login and Registration Log in · Register