I'm working on solution in Power Automate to send a customised news digest from SharePoint Online. For this I am using a HTML table where the news article title, description, link and thumbnail are added to the table and then sent via email.
The solution works fine when populating textual data (strings), such as the article's title and description. However, it does not seem to work when trying to parse in an image URL. As you can see in the screenshot below, I've attempted to use the <img> tag to display the thumbnail, but the HTML table is displaying this as literal raw text.
Is there a way I can make the HTML table parse the image URL as an image?
Thanks!
I noticed it only happens when selecting the Stock Images in SharePoint.
Hello,
I used Vlad1 for the Filepath expression:
substring(items('Apply_to_each')['Thumbnail'], indexOf(items('Apply_to_each')['Thumbnail'], '_layout')
That was working until I selected an image from Outlook web images in our tenant, then I got this error on my flow:
Unable to process template language expressions in action 'Filepath' inputs at line '0' and column '0': 'The template language function 'substring' parameter is out of range: 'start index' must be non-negative integer and should be less than the length of the string. Please see https://aka.ms/logicexpressions#substring for usage details.'.
The first expression didn't work, giving me a access denied error:
join(skip(split(items('Apply_to_each')['Thumbnail'], '/'), 3), '/')
Any help you can provide is appreciated!
Hi @Anonymous - here's how we build the articles portion of our email. We use a variable to store the Link to Item value because we populate that with an alternate link if it's a repost news item.
No it's not sensitive... it's just the test...
here is the HTML for the link that is not working
and here is the link to my working example
Show an example of the final HTML that is produced. If you view the source of the email in outlook does the content and HTML look correct?
You can PM it to me if it is sensitive.
I tried that as well but not working
You do not have double quotes around the link. Your example would produce:
<a href=https://....><p>....
But you need
<a href="https://..."><p>...
hi @Paulie78! thanks for your reply.. yes it is not taking the <a href =" " >text</a> in the URL... all my work is complete except this one... this is how I am passing my Link in the code
and this is how I am setting my Select action
is there anything I can add to get it resolved... your help would be highly appreciated
I don't think I understand the problem. The link in your screenshot looks ok, so is it changing before it gets delivered in the email?
hi @Paulie78 thanks for your help... the method helps me to resolve the image-related issue but now m facing a new problem... the 'Link to item' is not working, when I see the output of my select it's showing me the exact link to the post but appending to string variable is not adopting this...
any help would be great!... I commented on your video as well but did not get any reply 😞
Tomac
986
Moderator
stampcoin
699
Super User 2025 Season 2
Riyaz_riz11
577
Super User 2025 Season 2