'how can I get the URL of feature image in RSS feed
I have a URL of my RSS feed website and I want to access to the details in this URL in another website but I have some issue! I can get the title and the link is this Feed but I cant get the feature image and I DONT know how to code it !
feature image is in the <description> tag but I DONT know how to get it !
here is my code :
$rss_feed = simplexml_load_file("https://asphaltshop.ir/product-category/hoodie/feed");
if(!empty($rss_feed)) {
$i=0;
foreach ($rss_feed->channel->item as $feed_item) {
if($i>=10) break;
?>
<div> <img src="<?php echo $feed_item->description; ?>"> <a class="feed_title" href="<?php echo $feed_item->link; ?>"><?php echo $feed_item->title; ?></a></div>
<?php
$i++;
}}
}
and here is my URL of RSS feed :
https://asphaltshop.ir/product-category/hoodie/feed
please someone tell me how can I get the image with changing this code!
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
