• Resolved durangod2

    (@durangod2)


    Hi i think i may have accidently removed the author display from under the product listing but i cant figure out where or how i did it..

    How do i put it back, i want to show the product author on each product displayed in the store..

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Support Hannah S.L.

    (@fernashes)

    Automattic Happiness Engineer

    Hey there,

    By default, WooCommerce doesn’t show a product’s author – it’s not something you’d usually see on an e-commerce site. Here’s what it looks like on my sandbox site using WooCommerce and the Storefront theme:

    Product without author
    Link to image: http://cld.wthms.co/eReVS7

    You may be expecting to see the vendor’s name, if the product is being sold by a vendor – in that case, you could look into our Product Vendor’s plugin:
    https://www.woocommerce.com/products/product-vendors/

    Thread Starter durangod2

    (@durangod2)

    Thank you so much for the reply. I have been going crazy trying to put plugin pieces together to make a whole multi vendor software store. That product vendors plugin sure looks like exactly what i need..

    Create a Custom Field for this and then add it. Simple as that.

    Sorry, forgot to add link to custom fields.
    https://codex.wordpress.org/Custom_Fields

    • This reply was modified 6 years, 1 month ago by stefsternyc.
    Thread Starter durangod2

    (@durangod2)

    Thanks for the link stefsterNYC, but sadly im not doing a post i am displaying a product via woo commerce. And i would have to replace the special coding every time there is an update. I did try several custom field plugins but sadly they are either not complete or they have tons of coding issues. So maybe that expensive plugin will do that job… im still not sure because i really cant afford it but then again my project really needs it.

    Custom Fields are for both. A product is essentially a post. I do it everyday. You would not have to change the code every time there’s an update. Any time you want to do something outside of WC you have to copy the file to your theme. That’s just how it is. Then you are all set. Updating will not ruin your theme or your life.

    It’s that simple.

    There may be a plugin but plugins also slow your site down, are trojan horses for hackers to attack your site. A simple script and your done.

    I’m not sure where you want to put the author’s name but it would be something like this. Granted I’m using tabs to display the custom content but it’s very similar to this. Where it says $custom_tab that’s my custom field for WC. Then in the admin backend of your product you simply create a custom field called custom_tab and put a value inside it. Author’s name. I realize you may have no coding experience and if so it’s easier to just hire a dev to do this.

    add_filter( 'woocommerce_product_tabs', 'woo_new_product_tab' );
       function woo_new_product_tab( $tabs ) {
       
         // Adds the new tab
           $tabs['test_tab'] = array(
                 'title'     => __( 'Ingredients', 'woocommerce' ),
                 'priority'  => 10,
                 'callback'  => 'woo_new_product_tab_content'
        );
    
        return $tabs;
    
    }
    function woo_new_product_tab_content() {
    
    $custom_tab = get_post_meta( get_the_ID(), 'custom_tab', true);
        
            if( ! empty( $custom_tab ) ) {
            echo '<p>' . $custom_tab . '</p>';
        }
        
    }
    Thread Starter durangod2

    (@durangod2)

    Yes i can follow that to a point. I am a php programmer from the old days. I am not really familiar with WP structure. I am familiar with MVC Model-View-Controller structure and i did build a store plugin for Oxwall an open source social script.

    I was using plugins for a few reasons, first because our project is just starting out and i dont want to jump in with both feet until i know its going to work. Also because if i coded one myself which i could, i would have to make it closed source and probably ionCube it and then if something happens to me then what do the other team members do, they are sunk because i would have the only source copy.

    Then coding my own i would have to store the IPN data from paypal and i dont want to store data like that with all the privacy witch hunt going around now. Its bad enough having to store paypal email addresses with a plugin, that i can deal with but the IPN has much more data inside it and that i am not willing to store on my server.

    Then there is the time factor i need to have this store up and running by the end of sept. Which if i start now coding i could do, but do i want to push myself that hard again, i am retired.

    I was hoping that WC plugin would give me all i need to do what i need to do which is layed out here.

    https://wordpress.org/support/topic/what-extensions-do-i-need/

    So all in all alot to consider, spend money on one hand, or deal with the schedule and stress on the other hand. However i will say if i coded my own, i would know exactly how it worked, what is where, exactly how to fix issues, and it would just cost me time is all. 🙂 Sorry to be so long winded 🙂

    • This reply was modified 6 years, 1 month ago by durangod2.
Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Add author under product listing’ is closed to new replies.