WordPress.org

Ready to get started?Download WordPress

Forums

WooCommerce - excelling eCommerce
Forcing WC Products to use Pages instead of Posts? (9 posts)

  1. Linii
    Member
    Posted 1 year ago #

    Is there any way to force WooCommerce to post listings and descriptions into a Page instead of a Post only? Right now it uses it's own "hidden post" system, but still acts as a post versus a page on full item descriptions. There are some themes out there that are beautiful, however have no support, however if you post to a "Page" it works, but you'd have to link everything manually and get creative. Is there a way to tell WC hey, I want you to make this a page, and not a post, or a post and not a page, etc? This way it would be able to show up properly with different layouts. Thanks! :)

    http://wordpress.org/extend/plugins/woocommerce/

  2. Roy Ho
    Member
    Posted 1 year ago #

    "post", "page" and "product" are all custom post types. So what you can do with one you can do with any of them.

    Why do you believe that styling is easier on a page than on product post type?

    Perhaps you have a specific question so I can better help you?

  3. Linii
    Member
    Posted 1 year ago #

    Hi Splashing thanks for the offer of the help. I set up a temporary site to show what is happening.

    First please click on the Shop link. You will see its horribly misformatted due to a theme issue, but every other link on the menu bar brings up a nice black bordered white page that's centered. Please click "how I want my product & product detail to look and feel". This page was set up automatically with correct formatting because it was manually made as a Page and wasn't a post. So basically, instead of the way the cart is now -- I want all of the stuff that's in there inside the nice pretty box that the pages set up automatically with little to no effort.

    Is there a way to force my product icons to fit into that specific frame? The only workaround I find right now is to manually upload all pictures, use the thumbnails with a photoshopped "add to cart" button, and a hyperlink to add manually to the cart -- which works okay, but then I miss out on a description page.

    So I basically want:

    This & This

    To be inside the same format/layout as this. Without having to take a long workaround. I hope that helps with better explanation and detail.
    Thank you in advance. The theme I am using is Shuttershot.

  4. Roy Ho
    Member
    Posted 1 year ago #

    This is not difficult to do but will take several trial and error because every theme is a bit different.

    First you need to mimic the container your page uses ( the one in the white box ). So find how it is constructed in terms of the outer most wrapper container and then use the following hooks.

    'woocommerce_before_main_content'
    'woocommerce_after_main_content'

    Those hooks are quite self-explanatory so the first hook you will inject the beginning of your white box's outer container code. And the second hook you close the container with the white box's closing outer container code.

    That is the first step in making this work. Try that and see how it goes.

    So what this does is whenever you're on a product category page, it will use these action hooks to manipulate the HTML.

  5. Linii
    Member
    Posted 1 year ago #

    Oh goodness. This is going to make my brain explode since I haven't really touched code and I'm just getting my feet wet. Am I looking in the page.php of this theme? Can you help walk me through it? =P I'd be much obliged!

  6. Roy Ho
    Member
    Posted 1 year ago #

    Again as I stated above, every theme is different so I would not really know how your theme works. I can only give you my suggestion and give a general guidance on how to approach this.

    I think a good way is just to look at the generate source. You can use tools like firebug or chrome tools to see the underlying code which will reveal how it is put together in terms of the HTML markup.

  7. Linii
    Member
    Posted 1 year ago #

    Ok so am I just trying that code above without any syntax other than the apostrophe's?

  8. Roy Ho
    Member
    Posted 1 year ago #

    No, no...Those are only hooks. You would need to write your own custom functions to make them work.

    I would suggest you start by reading/studying this -> http://docs.woothemes.com/document/third-party-custom-theme-compatibility/

    Then go here to study hooks -> http://codex.wordpress.org/Plugin_API/Action_Reference

  9. Linii
    Member
    Posted 1 year ago #

    All right.. thanks for the help and sorry for the newbieness.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.