Dynamic field description (specifications)

Hi everyone,

I’m brand new to Shopify. It’s a great website builder, but I’m having trouble understanding metafields, variables, and objects.

Let me explain what I’m trying to do. Maybe some of you pros can help me out!
For example, let’s say I have a product: socks. I want to display something like this:

Material: Cotton

For another product, like jeans, I want to show:

Size: S

Ideally, I would like the text to be fully dynamic, including both the label (“Material”, “Size”, etc.) and the value (“Cotton”, “S”), all within the same field.

Currently, I have something like this:

However, I’d also like the word before the colon to be dynamic.

I also need to display several product specifications in the same field, ranging from four to ten, depending on the product.

Thank you for any help

Hey K,

Sorry for the delay here. Let me provide some information in case you haven’t been able to get what you want here and you can tell me if you need more guidance.

One of the fundamental things to understand about custom data is that you typically want to follow the pattern of:

  1. Create a Metaobject definition (in this case it may be a text-field with the title of “Size”
  2. Add all the available sizes as Entries in the Metaobject
  3. Create a Metafield definition and assign it to the Product or Collection resource type
  4. Go to your Product or Collection and you’ll see that new Metafield listed and you can choose the Size

That said, in this case you may be able to use Taxonomy (A card titled Category Metafields on the product card) to add the “Fabric” to the Socks. And you also may be able to use Variants to set the Size of the Jeans. There are shops who choose not to use the Variants and Taxonomy features and use Metafields & Metaobjects instead or in addition to.

As for adding this content into your online store, this is pretty dependent on your theme or how far you want to go with the liquid code directly that determines the page design. Most themes will have some sort of dynamic content blocks (where you can choose a metafield or metaobject value to be displayed) as you’ve shown in your screenshot. You can then link your Metaobject to the product page, and whatever selections you have made on that product for your “Size” metaobject will appear on the page.

This doesn’t solve how to line up all the text exactly how you’d like. You may need to go right into the Liquid code and modify some of that to put the pieces together. Unless your theme has some form of small text box that is a dynamic sourced field.