I have the following code:
$feed->item([
'title' => $post->title,
'guid' => $post->guid
]);
which generates the following output for me:
<title>Title of post</title>
<guid>Guid of the post</guid>
I want to include the following tag in it
<enclosure url="image.jpg" length="1" type="image/jpeg"/>
How this will be possible, considering that the code above, generated automatically an opening and closure tag for each attribute.
PS: The library im using is: https://github.com/thujohn/rss-l4
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire