StackIdeas
Get cover image by article ID
By
Zeosing
on Wednesday, 23 May 2018
Posted in
Technical Issues
Likes
0
Views
685
Votes
0
Hi, this is a bit tricky, we need to show the cover of a certain article by his id.
Of course when we don“t access or not loaded array $post
Thanks.
You can load a post cover of any post by issuing the codes below:
[gist]
// You need to replace $postId with the proper variable
$post = EB::post($postId);
var_dump($post->getImage());
[/gist]
Mark
·
Wednesday, 23 May 2018 22:35
·
0 Likes
·
0 Votes
·
0 Comments
·
#413503
Perfect Mark, as always.
Thanks
Zeosing
·
Wednesday, 23 May 2018 23:55
·
0 Likes
·
0 Votes
·
0 Comments
·
#413514
You're most welcome.
Arlex Wong
·
Thursday, 24 May 2018 10:14
·
0 Likes
·
0 Votes
·
0 Comments
·
#413551
View Full Post