Email template | Insert custom HTML block above the subject

271 Views Asked by At

Im trying to add gmail markups to the top of the order confirmation email like showed in the picture

enter image description here

I tried using the gmail provided markup code:

<script type="application/ld+json">
{
  "@context": "http://schema.org",
  "@type": "Order",
  "merchant": {
    "@type": "Organization",
    "name": "Amazon.com"
  },
  "orderNumber": "123-4567890-1234567",
  "priceCurrency": "USD",
  "price": "29.99",
  "acceptedOffer": {
    "@type": "Offer",
    "itemOffered": {
      "@type": "Product",
      "name": "Google Chromecast"
    },
    "price": "29.99",
    "priceCurrency": "USD",
    "eligibleQuantity": {
      "@type": "QuantitativeValue",
      "value": "1"
    }
  }
}
</script>

But with no luck.

Im using a docker with magento 2 and mailhog (locally). Mailhog recieves the order mail. The script exists in the <head> part (with inspect element) but does not get rendeded.

Also tried to sned that exact code using gmail.com to myself - it does not get rendered either.

What im missing?

0

There are 0 best solutions below