このワークフローでは、HTMLタグを使用してメールの本文を変更することで、ビジネスルール通知に画像を含める方法について説明します。
このワークフローには以下のステップが含まれます。
ステップ1:画像を選択する
メールの本文に含める画像を見つけ、その画像のダイレクトURLを取得します。
たとえば、このダイレクトURLをもつ以下の画像を使用するとします。https://dam.zendesk.com/m/4a25a18730907a7/webimage-Logo_Types_Primary-espresso
ステップ2:トリガのアクションを編集する
トリガのアクションのメールの本文に、<img src="image_url">
を含めて、image_url
の部分を画像のダイレクトURLで置き換えます。
ステップ3:トリガをテストする
トリガをテストし、すべて正しく機能することを確認します。トリガ条件を追加して、トリガがテストチケットでのみ実行されるようにします。たとえば、「チケット」 > 「タグ」が | 少なくとも次の1つを含む | testforhtml
という条件を追加して、受信したメール通知を確認します。
HTMLを使用して、画像のサイズをメールの他の部分に合わせることもできます。詳細については、w3schoolsを参照してください。
免責事項:この記事は説明のみを目的として提供されています。記事内で例示したコードについて、Zendeskはサポートも保証もいたしません。何か問題があった場合はコメント欄に投稿するか、インターネットで解決策を探してみてください。
20件のコメント
Miriam Valdelvira
Cela n'a pas marché pour moi, une alternative ?
0
Chris Harman
After recent changes to your menus, it's now much easier to add a logo to trigger notifications. I could copy and paste the logo from our website into the message body. I clicked on the HTML editor, and it looks like Zendesk adds most of it for you now. I wish it was easier to resize images for people who don't know HTML, but still a big improvement.
0
Operations
Hello,
I've had the same issue, added the following to my trigger body <img src="https://ibb.co/XVWmvZY"> but the image is broken (I use Outlook and can only see what the image shows below).
The image format is .png so I know that's not the issue. I would appreciate any help. Thank you.
0
Mario Dalla Costa
Como incluir uma imagem ou foto no corpo do e-mail? Uma imagem que esteja arquivada no meu pc. A opção de html não é válida para esta necessidade.
0
Noly Maron Unson
Hi mfg,
The same should also apply since it will be up to the user's end how they will handle the image. How their client handles the images will depend on their system settings, restrictions, etc.
Hope this helps.
0
mfg
Having the same issue here and I keep getting that this is related to the image download setting in Outlook and Gmail. I spoke with our Marketing team, who sends comms with images all the time and they've reported that they're aware some end users won't have images on auto-download but they're comfortable with it.
The difference though is that I want to make these updates to the global email channel template - but this article is written about using images in triggers. Do the same practices above apply?
0
Guilherme Santi Clair Da Silva
Caros, boa tarde!
Consigo mandar a imagem do dashboard que programei a entrega no corpo do e-mail?
0
Silas Johnson
Thanks again! i'll keep playing with it. I got it to send with a trigger, but image is broken
1
RichL
Silas Johnson To troubleshoot, I'd say first try to get it working in a trigger. I'm assuming you're trying to insert this image into the email message body, right? Try putting the image tag into the email body and setup the trigger so that it will only fire on a ticket that you update. I had a problem with a wayward space in my image tag, so it could be something like that.
In the automation, I'm not sure if you need to put it into valid HTML. That's the only way I am using images in email body from an automation as part of my CSAT survey. You could try adding the <html> <head> and <body> tags and all of that to make it valid HTML. Not really sure though without trying it out myself. Good luck!
0
Silas Johnson
Maybe its because I didn't do it in a trigger?
0
サインインしてコメントを残してください。