Shopify themes, liquid, logos, and UX
Hi,
I'm relatively new to Shopify liquid and I am trying to add the product name to the "New Gift Card" template under notifications.
I looked through the liquid variables and couldn't see any product information related to Gift Cards, so I used the following code in the template but it doesn't appear to be working.
Anyone got any suggestions?
<table align="center" class="row giftcard__topmargin"> {% for line in subtotal_line_items %} <tr> <td> {% if line.product.title %} {% assign line_title = line.product.title %} {% else %} {% assign line_title = line.title %} {% endif %} {{ line_title }} </td> </tr> {% endfor %} </table>
Also, just as a side quest question, in PHP, for example, I can use print_r() to print out an array of items that I can use on the page, is there an equivalent in liquid? For example, could I print_r(subtotal_line_items)?
2m ago Learn the essential skills to navigate the Shopify admin with confidence. T...
By Shopify Feb 12, 2025Learn how to expand your operations internationally with Shopify Academy’s learning path...
By Shopify Feb 4, 2025Hey Community, happy February! Looking back to January, we kicked off the year with 8....
By JasonH Feb 3, 2025