We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more

Using metaobjects to create a category specific FAQ to display on my product pages.

Using metaobjects to create a category specific FAQ to display on my product pages.

OliviaMichaelCo
Pathfinder
131 10 32

Hello all.

I want to add an FAQ to my product page, but I want the FAQ displayed on the product page to be specific to each product category. I have only three main product categories: Candles, Wax Melts, and Reed Diffusers.

As a result, I have created three FAQ metaobjects:

  • Candles FAQ
  • Wax Melts FAQ
  • Reed Diffuser FAQ

Each of these FAQ metaobjects has around 8-10 entries. Each entry comprises two fields: a question and an answer.

What I had hoped I could do, is create a product metafield definition, called Candle FAQ, for example, assigned to the category of 'Candles' and then anytime a user was on a product page for a candle, I could use the FAQ metaobject in a collapsible row.

Nope, not that simple. You can't do that.

So I then thought I'd have to go into each product itself, select the metaobject from the category metafields section so it's at least linked to the FAQ. Not the end of the world.

Nope, not that simple. You can't do that.

What it appears I have to do, is set the candle FAQs metafield definition to the metaobject Candle FAQs, as a list of entries, and then go into my 60+ products, and select every entry within the FAQ for it to appear on the product page.

There has to be an easier way... Surely?

Does anyone know the simplest way to create an FAQ list, and link it to a product category to make it show on a product page that is specific to the product category? I'd really appreciate some help here. I even went as far as to try and create a new section called dynamic-faqs.liquid, but it couldn't read the metaobject data for some reason, it knew there was data but couldn't access it, despite allowing storefront access.

Any help greatly appreciated, thanks.

Rosalind.

Replies 4 (4)

devcoders
Shopify Partner
1654 190 545

Hello @OliviaMichaelCo 

Thank you for submitting your query to the Shopify community. I’d be happy to assist you. Could you please provide the store URL and password (if it’s password-protected) so I can review and get back to you with an update?

Shopify Developer: Helping eCommerce Stores
If you need assistance with your store, feel free to contact us at devcodersp@gmail.com
WhatsApp No: +91 8516919310 If my assistance was helpful, please consider liking and accepting the solution. Thank you!
OliviaMichaelCo
Pathfinder
131 10 32

I've not added anything to my store yet, so there's nothing on the store to see that would help answer this question. Everything is in the backend at the moment, all in metaobjects.

devcoders
Shopify Partner
1654 190 545

Hello @OliviaMichaelCo 
Okay, so please let me know how I can check, or you can send me store access so I can review the backend and provide you with the details.

Shopify Developer: Helping eCommerce Stores
If you need assistance with your store, feel free to contact us at devcodersp@gmail.com
WhatsApp No: +91 8516919310 If my assistance was helpful, please consider liking and accepting the solution. Thank you!

PaulNewton
Shopify Partner
8031 688 1649

Hi @OliviaMichaelCo Metaobjects(MOBS) are flexible but not automagic.

As you've found MOBS don't auto-populate|auto-repeat blocks or content in parts of a themes UI for each MOB entry.

The themes editor/settings system, for the online sales channels,  has no concept for that type of conditional looping behavior, submit use cases and feature requests to shopify support directly. It basically has to be done custom to be effective.

 

The klunky way shopify has done MOBS makes them third class data citizens. Beyond the most crudest reductive narrow use cases MOB are really there to be leveraged in creating a process that consumes them*. We can't even do simple setups like usinga  MOB that represents an archived product without heavy theme work because of the .value and entry looping nonsense means every sub property/object has to be hard changed in templates instead of a simple object swap.

*kinda like custom-post-types in wordpress in a very abstract abstracted way.

 

Approaches:

  • For resource templates manually setup each dynamic source in the theme editor 🤢
  • or for resource templates manually edit the templates JSON file to enter values 🤢.  👨‍💻🥋 If excel-fu is strong export the MOBs , get the entry handles, and output a template JSON with settings using the entries as dynamic sources.
  • Or do that for a MOB webpage templates and embed the MOB webpage as an iframe elsewhere and deal with the dominoes of that approach.
  • Or create a custom section as an advanced theme customization

If you need this as a theme customization then contact me for services.
Contact info in forum signature.
ALWAYS please provide context, examples: store url, theme name, post url(s) , or any further detail in ALL correspondence.

Contact paull.newton+shopifyforum@gmail.com for the solutions you need


Save time & money ,Ask Questions The Smart Way


Problem Solved? ✔Accept and Like solutions to help future merchants

Answers powered by coffee Thank Paul with a Coffee for more answers or donate to eff.org