• Resolved titsmaker

    (@titsmaker)


    Hi, can someone point out where’s the code responsible for the product title generation? I tried following the code but it seems that WC template structure is just too complicated for me.

    I am asking because I noticed some inconsistencies, namely product title is shown in different way for backordered and in stock products (for variable products). Both attributes are added to the product title for in stock products while only one attribute is shown for backordered products. Unfortunately I don’t have products with 3 attributes so I don’t know how WC will handle their titles. To clarify I see these titles in following places (cart and checkout pages, admin edit order page, customer and admin order related emails). My theory that there’s some attribute number cap after which the format is changed and “backordered” is treated as just another attribute (which is weird).
    I tried switching off ‘woocommerce_product_variation_title_include_attributes’ and ‘woocommerce_is_attribute_in_product_name’ filters which I was using and noticed more strange things – while these filters were affecting the look of product name in the cart and checkout in the meantime product names were not affected in the admin section (order details page). Older orders have product names without attributes while newer ones have product names with attributes and filters does not affect this. The border between two resembles the time when I introduced aforementioned filters. I don’t use any cache, so it is out of question. So my last guess is – maybe some transients are used for those titles?
    What I want is both backordered and in stock products to have same product title format containing all attributes names but I have no idea how I can change this.

Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.