Loại bỏ chữ product và product-category trong WooCommerce

Permalink-plugin

Loại bỏ chữ product và product-category trong đường dẫn của WooCommerce một cách đơn giản.

Theo mặc định, trong đường dẫn (permalink) của WooCommerce sẽ có thêm chữ product (sản phẩm) và product-category (danh mục sản phẩm). Điều này giúp phân biệt với đường dẫn của bài viết hay các chuyên mục của bài viết. WooCommerce không khuyến khích việc loại bỏ những chữ này để tránh lỗi trùng lặp hay xung đột đường dẫn giữa bài viết thông thường và sản phẩm. Tuy nhiên, nhiều bạn vẫn muốn loại bỏ chúng để đường dẫn của sản phẩm ngắn gọn hơn, thân thiện với công cụ tìm kiếm hơn.

Loại bỏ chữ product và product-category trong WooCommerce

Có nhiều phương pháp khác nhau để làm điều này, cả plugin lẫn code snippets. Tôi thấy một số trang đang chia sẻ code snippets giúp tùy biến đường dẫn của WooCommerce mà không cần dùng plugin. Cụ thể ở đây là code:

Tuy nhiên, trên thực tế những code này không tối ưu nên gây ảnh hưởng nghiêm trọng đến hiệu suất của website. Cụ thể, chúng có thể làm CPU và RAM của host bị quá tải, dẫn đến website load rất chậm, thậm chí bị lỗi 503 (quá tải). Tôi đã từng ghi nhận tình trạng này trên website của một số khách hàng. Các bạn tuyệt đối không nên sử dụng chúng.

Trong bài viết này, tôi sẽ giới thiệu cho các bạn cách đơn giản mà hiệu quả nhất, ít gây ảnh hưởng tới hiệu suất hoạt động của website.

1. Đầu tiên, các bạn cần phải cài đặt và kích hoạt một plugin có tên là Premmerce WooCommerce Permalink Manager Pro.

Toi-uu-duong-dan-product-premmerce-permalink-manager-1
Toi-uu-duong-dan-product-premmerce-permalink-manager-1

2. Tiếp theo, click vào nút Allow & Continue.

Toi-uu-duong-dan-product-premmerce-permalink-manager-2
Toi-uu-duong-dan-product-premmerce-permalink-manager-2

3. Giao diện thiết lập của plugin sẽ trông giống như thế này. Hãy lựa chọn dạng cấu trúc đường dẫn phù hợp với nhu cầu của bạn.

Toi-uu-duong-dan-product-premmerce-permalink-manager-3
Toi-uu-duong-dan-product-premmerce-permalink-manager-3

Trong đó:

  • Use WooCommerce settings: sử dụng thiết lập permalink của WooCommerce. Thiết lập này các bạn có thể tùy biến tại Settings => Permalinks. Nó nằm ngay bên dưới phần thiết lập permalink của WordPress.
  • Category slug: sử dụng đường dẫn danh mục sản phẩm kiểu tenmien.com/ten-danh-muc-san-pham.
  • Product slug: sử dụng đường dẫn sản phẩm kiểu tenmien.com/ten-san-pham.
  • Full category path: sử dụng đường dẫn danh mục sản phẩm kiểu tenmien.com/ten-danh-muc-me/ten-danh-muc-con.
  • Product slug with primary category: sử dụng đường dẫn sản phẩm kiểu tenmien.com/ten-danh-muc-san-pham/ten-san-pham.
  • Full product path: sử dụng đường dẫn sản phẩm kiểu tenmien.com/ten-danh-muc-me/ten-danh-muc-con/ten-san-pham.

Tick vào các mục Use primary category và Add canonicals để tăng khả năng tương thích cho plugin. Cuối cùng, click vào nút Save Changes để lưu lại.

4. Xóa cache website (nếu bạn có sử dụng plugin tạo cache) và kiểm tra kết quả. Thật đơn giản phải không nào? Chúc các bạn thành công!

337 thoughts on “Loại bỏ chữ product và product-category trong WooCommerce

  1. Pingback: cialis review

  2. Pingback: canadian viagra pharmacy

  3. Jesseemerm says:

    Thank you for the auspicious writeup. It in fact was a amusement account it. Look advanced to more added agreeable from you! By the way, how could we communicate?

  4. Jesseemerm says:

    It’s in reality a nice and useful piece of info. I’m satisfied that you just shared this helpful information with us. Please keep us informed like this. Thanks for sharing.

  5. Jesseemerm says:

    Thanks for the auspicious writeup. It in truth was once a enjoyment account it. Glance complex to far added agreeable from you! By the way, how could we communicate?

  6. https://elliottexqhz.blogozz.com/ says:

    Please let me know if you’re looking for a writer for your weblog.
    You have some really great articles and I feel I would be a good asset.
    If you ever want to take some of the load off, I’d love to
    write some material for your blog in exchange for a link back to mine.
    Please send me an email if interested. Kudos!

  7. Jesseemerm says:

    Hi there to all, the contents existing at this web page are genuinely remarkable for people knowledge, well, keep up the nice work fellows.

  8. mikrolån says:

    I every time used to read paragraph in news papers but now as I
    am a user of web therefore from now I am using net for content, thanks to web.

  9. bilrecensioner says:

    Hey there I am so happy I found your weblog,
    I really found you by mistake, while I was looking on Aol for something else, Anyways I am here now and
    would just like to say many thanks for a tremendous post and a all round entertaining
    blog (I also love the theme/design), I don’t have time
    to read it all at the minute but I have saved it and also added your RSS feeds,
    so when I have time I will be back to read more, Please do keep
    up the fantastic b.

  10. Pingback: cialis and viagra

  11. beautqkdx.blogsumer.com says:

    We stumbled over here from a different website and thought I might as
    well check things out. I like what I see so now i’m following you.
    Look forward to looking at your web page yet again.

  12. Jesseemerm says:

    Hi, I do believe this is a great blog. I stumbledupon it 😉 I will come back once again since I saved as a favorite it. Money and freedom is the best way to change, may you be rich and continue to help others.

  13. Jesseemerm says:

    Spot on with this write-up, I really believe this site needs much more attention. I’ll probably be back again to read through more, thanks for the information!

  14. Pingback: sildenafil 25 mg

  15. payroll outsourcing says:

    Having read this I thought it was rather enlightening.

    I appreciate you spending some time and effort to put this short article together.
    I once again find myself personally spending a lot of time
    both reading and commenting. But so what, it was still worth
    it!

  16. Jesseemerm says:

    Nice post. I learn something new and challenging on websites I stumbleupon everyday. It will always be exciting to read through articles from other authors and practice a little something from their web sites.

  17. Jesseemerm says:

    You really make it seem so easy with your presentation but I find this matter to be actually something which I think I would never understand. It seems too complicated and extremely broad for me. I’m looking forward for your next post, I’ll try to get the hang of it!

  18. Jesseemerm says:

    Wow! In the end I got a website from where I know how to really take helpful facts concerning my study and knowledge.

  19. Jesseemerm says:

    Hi, I do believe this is a great blog. I stumbledupon it 😉 I’m going to revisit yet again since i have saved as a favorite it. Money and freedom is the greatest way to change, may you be rich and continue to help others.

  20. Pingback: canadian cialis 20mg

  21. Pingback: online viagra sales

  22. adelaide acupuncture says:

    Heya i’m for the first time here. I came across this board and I find It really useful & it helped me out a lot.

    I hope to give something back and aid others like you aided
    me.

  23. Jesseemerm says:

    Greetings I am so happy I found your site, I really found you by mistake, while I was researching on Digg for something else, Anyways I am here now and would just like to say many thanks for a remarkable post and a all round exciting blog (I also love the theme/design), I don’t have time to go through it all at the moment but I have saved it and also added in your RSS feeds, so when I have time I will be back to read much more, Please do keep up the excellent work.

  24. Sally says:

    It’s awesome in support of me to have a site, which is helpful in favor of my knowledge.

    thanks admin

  25. Online drugstore pharmacy says:

    I’m truly enjoying the design and layout of your blog.
    It’s a very easy on the eyes which makes it much more pleasant for me to come here and visit more
    often. Did you hire out a designer to create your theme? Outstanding work!

  26. Jesseemerm says:

    I do accept as true with all the concepts you have offered for your post. They’re very convincing and can definitely work. Nonetheless, the posts are too quick for novices. May just you please prolong them a bit from next time? Thanks for the post.

  27. Finn says:

    Hi, I do think this is a great website. I stumbledupon it 😉 I’m going to return once again since i have saved as a favorite it.

    Money and freedom is the best way to change, may you be rich and continue to guide other people.

  28. Pingback: cialis dosage recommended

  29. Marlys says:

    Greetings! This is my first visit to your blog! We are a team of
    volunteers and starting a new initiative in a community in the same niche.
    Your blog provided us beneficial information to work on. You
    have done a wonderful job!

  30. Jesseemerm says:

    I love what you guys tend to be up too. This sort of clever work and reporting! Keep up the terrific works guys I’ve you guys to my blogroll.

  31. Pingback: buy sildenafil 20

  32. David Denis says:

    I am sure this post has touched all the internet visitors, its really really fastidious article on building up new website.

  33. Jesseemerm says:

    Ahaa, its pleasant discussion concerning this article at this place at this blog, I have read all that, so now me also commenting here.

  34. Shannon Waddell says:

    I like what you guys tend to be up too. Such clever
    work and exposure! Keep up the superb works guys I’ve added you
    guys to my personal blogroll.

  35. Jason Martinez says:

    It is the best time to make some plans for the longer term and it is time to be happy.
    I have learn this post and if I may I desire to recommend you some interesting
    issues or suggestions. Perhaps you can write subsequent articles regarding this article.
    I wish to learn more things approximately it!

  36. Paul Kujawski says:

    Hi there! This post couldn’t be written any
    better! Looking at this article reminds me of my previous
    roommate! He constantly kept preaching about this. I am going to forward this information to
    him. Pretty sure he will have a great read.
    I appreciate you for sharing!

  37. Madison says:

    Hi there! I’m at work browsing your blog from my
    new iphone! Just wanted to say I love reading your blog and look forward to all
    your posts! Carry on the superb work!

  38. Earl Ragas says:

    Its like you learn my thoughts! You appear to grasp a lot about this, like you wrote the ebook in it or something.
    I feel that you could do with a few % to power the message house a little bit, however other than that, this is wonderful blog.
    A fantastic read. I’ll certainly be back.

  39. Jesseemerm says:

    Hey there! Do you know if they make any plugins to help with SEO? I’m trying to get my blog to rank for some targeted keywords but I’m not seeing very good results. If you know of any please share. Thanks!

  40. Jesseemerm says:

    Hi everybody, here every one is sharing such know-how, thus it’s nice to read this website, and I used to pay a quick visit this webpage everyday.

  41. Spotify plaque says:

    Good day! I know this is somewhat off topic but I was wondering if
    you knew where I could get a captcha plugin for my comment form?
    I’m using the same blog platform as yours and I’m having difficulty finding one?
    Thanks a lot!

  42. Jesseemerm says:

    Heya i am for the first time here. I found this board and I find It really useful & it helped me out much. I hope to give something back and aid others like you helped me.

  43. Tamara Bass says:

    Hi there, There’s no doubt that your blog could possibly
    be having web browser compatibility issues. Whenever I look at your web site in Safari, it looks fine however when opening in IE, it’s got some overlapping issues.
    I simply wanted to give you a quick heads up! Other than that, wonderful site!

  44. David Ruggs says:

    I really love your website.. Excellent colors & theme.
    Did you create this web site yourself? Please reply back as
    I’m attempting to create my own personal site and would love to know where you got this from or exactly what the theme is called.
    Kudos!

  45. lorenzocefee.blogs-service.com says:

    I was wondering if you ever thought of changing the layout of your website?
    Its very well written; I love what youve got to say. But maybe
    you could a little more in the way of content so people could connect with it better.
    Youve got an awful lot of text for only having 1 or 2 pictures.

    Maybe you could space it out better?

  46. Deidra Alpern says:

    I’ve been browsing online more than three hours today, yet I by no means found any
    attention-grabbing article like yours. It’s pretty value sufficient for
    me. Personally, if all site owners and bloggers made just right content as you probably did,
    the web can be much more helpful than ever before.

  47. Hester Guy says:

    It is appropriate time to make some plans for the long
    run and it is time to be happy. I have read this post and if I could I desire to suggest you some
    attention-grabbing issues or tips. Maybe you
    could write subsequent articles relating to
    this article. I wish to learn more issues about it!

  48. Jesseemerm says:

    Hello, every time i used to check web site posts here early in the break of day, since i love to gain knowledge of more and more.

  49. Philip Eckhardt says:

    Heya i am for the primary time here. I came across
    this board and I find It truly helpful & it helped me out a lot.

    I am hoping to present one thing again and aid others such as
    you aided me.

  50. Jesseemerm says:

    After I originally left a comment I appear to have clicked on the -Notify me when new comments are added- checkbox and now whenever a comment is added I get 4 emails with the exact same comment. Is there a means you can remove me from that service? Thanks a lot!

  51. Colleen Heyd says:

    Ahaa, its good dialogue on the topic of this post at this place at this web site, I have read all that, so at this time me also commenting
    at this place.

Trả lời

Email của bạn sẽ không được hiển thị công khai.

093 608 8928