Edit shop page

We're shifting our Forum based support to a more dedicated support system!

We'll be closing our Forum support from 10th June, 2020 and move to Email Support assistance.

  • If you are a WCFM premium add-ons user, contact us- here
  • Want to know more before buying our add-ons? Send Pre sale queries- here
  • If you are a WCFM free user, please open a support ticket at WordPress.org
  • For WCFM App related queries, reach us- here
From now the forum will be read-only!

Viewing 9 reply threads
  • Author
    Posts
    • #127720
      iain.sandison
      Participant

      Love this but how do i edit the shop page?? I want customers to pick a store and shop through that retailer not browse a category of items with numerous listed sellers.
      Ive built store_list page and directing customers to their chosen store through there but then when you select a product and view in single item page it shows the breadcrumb link for the whole shop and that vendors store is forgotten

    • #127954
      Sushobhan
      Keymaster

      Hi,
      Previously I posted a reply with a snippet but it was not working. So I removed my reply. I’ll do some more research. The problem is WooCommerce doesn’t support this structure, see here- https://wordpress.org/support/topic/woocommerce-product-permalinks-custom-base/
      Will Let you know.
      Thanks!

    • #127962
      iain.sandison
      Participant

      Hi thank you so much for your efforts, its the only sticking point im having really so will look forward to your reply, thanks again appreciate it

    • #128068
      Sushobhan
      Keymaster

      Hi,
      Step 1: Please use the following snippet for this-

      add_filter( 'post_type_link', function( $post_link, $post, $leavename, $sample ) {
          if ( 'product' != get_post_type( $post ) )
              return $post_link;
      
          $authordata = get_userdata( $post->post_author );
          $author = $authordata->user_nicename;
          $post_link = str_replace( '%shop_name%', $author, $post_link );
          return $post_link;
      }, 50, 4 );
      
      add_action( 'init', function() {
          add_rewrite_rule( '(.?.+?)/product/?(.?.+?)/?$', 'index.php?author_name=$matches[1]&post_type=product&product=$matches[2]', 'top' );
      } );

      Add this code to your child theme’s functions.php
      In case you do not have child theme then add code using this plugin – https://wordpress.org/plugins/code-snippets/
      Step 2: Go to wp-admin >> Settings >> Permalinks, under Product permalinks section choose Custom base and input this- /%shop_name%/product/

      Let me know how this goes.
      Thanks!

    • #128169
      iain.sandison
      Participant

      Couldnt see any difference im afraid,

      Still links are
      Home-mystore-shop1-alcohol-lagers

      Then when i click a lager product it goes to single item page and links change to

      Home-alcohol-lagers

      So if a customer clicks alcohol tab thinking theyll go back to vendor it still goes to the shop page where catergories are and showing items from all sellers

      Is there a different way to do it? Am i doing it wrong or is woo commerce based more about the full shop rather than the vendors ?

      Thanks for your help again

    • #128360
      Sushobhan
      Keymaster

      Hello,
      I have gone through the other topic you have posted https://wclovers.com/forums/topic/links-breadcrumbs-on-shop-page/ . It helps me better understanding your requirement.
      Sorry but, this can’t be done that easily. I mentioned earlier WooCommerce by default doesn’t allow this kind of permalink structure.
      It will take time and effort. The last code I provided will not do. Please remove it to avoid any wrong redirections.
      You will need custom coding to make this possible.
      Thank You!

    • #128552
      iain.sandison
      Participant

      Well thanks for trying appreciate it, im a bit disappointed woo commerce doesnt have that option but there must be a way to do something maybe different. See the idea was a customer could pick a store vendor, shop with them browsing through all the categories they have adding to cart. Then they could visit another seller and browse their products adding them to cart also and then completing one checkout process.
      Example checkout basket

      Store 1
      Bread £1.00
      Milk £1.20

      Store 2
      Hammer £5.00

      Shipping £3.00
      Total £10.20

      Does that kind of make sense?

    • #128713
      Sushobhan
      Keymaster

      It’s hard to tell what will work best for the customers! Also, the frontend UI/UX depends on the business model as well. Like for Amazon, we don’t even care from which vendor we are buying the items as long as its “Fulfilled by Amazon”. There we mostly rely on search and similar item suggestions while making purchases. On the other hand in Etsy or Zatista, individual vendors/artists get more credits from their buyers.
      I agree, the breadcrumb structure you suggested make sense, as it makes navigation much easier. But, it will require some customization to have that inside WooCommerce.
      Thank You!

    • #128944
      iain.sandison
      Participant

      Hi thanks for your reply, how would i go about getting a bit custom Code help?

    • #129828
      Sushobhan
      Keymaster

      Hi,
      Please contact us here for this purpose- https://wclovers.com/setup-guidance/. After submitting the form please let me know here.
      Thank you!

Viewing 9 reply threads
  • You must be logged in to reply to this topic.