Get media by its own id. #2126
Answered
by
pkariuki
shankhadevpadam
asked this question in
Q&A
-
Is it possible to get the media by its one id? Without using the asscoiate model instance. |
Beta Was this translation helpful? Give feedback.
Answered by
pkariuki
Nov 4, 2020
Replies: 1 comment
-
$model->getMedia('media_collection')->where('id',$media_id)->first(); |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
freekmurze
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
$model->getMedia('media_collection')->where('id',$media_id)->first();