I am using mailchimp to send newsletters. Everything works fine apart from the fact that my RSS feed generated by Joomla does not contain the media:content tag, hence mailchimp doesn't show the images corellated to the articles.
The (hidden) menu through which the RSS feed is generated (the menu contains the latest articles, about 10 of them on each page of the menu) is a SP Builder Page, so I studied its' structure and located the div inside where the article links/images/title etc. are.
I wrote this simple JS script which parses the innerHTML properties of the div, thus displaying the image path in the server. However, that is a string with most of the time useless info. Example:
var imageDivs = Array.from(document.querySelectorAll(".article-intro-image"));
var linkOne = imageDivs[0]["innerHTML"];
var linkTwo = imageDivs[1]["innerHTML"];
var linkThree = imageDivs[2]["innerHTML"];
result:
linkOne = '\n\t\t\t\t<img src="/images/2022/02/05/E_thumbnail.jpg" alt="">\n\t\t\t'
linkTwo = '\n\t\t\t\t<img src="/images/2022/02/05/dsh_th.jpg" alt="">\n\t\t\t'
linkThree = '\n\t\t\t\t<img src="/images/2022/02/05/mixi_pi_1_thumbnail.jpg" alt="">\n\t\t\t'
As you can see there is some useless stuff there and I cannot slice each string a specified amount to get the needed info, as each image has a different length title.
Is there a way to fix the missing media:content tag through some Joomla extension (I have found solutions for WP, but not for j!) or perhaps to access the currentSrc attribute of each image in a similar way?
My question is quite complicated and I apologize for that, I would be happy to give any further explanation of the problem.