I am facing a dilemma while using Laravel - if I put a background image into my CSS style sheet, I lose my variable. Currently, this is how I have it set up:
<div class="gradient"><div class="topback" style="background-image: url('/storage/cover_images/{{$post->cover_image}}') ; background-size: cover; background-repeat:no-repeat; background-position: center center; ">
I am attempting to add a gradient overlay on top of the background-image in the gradient class. However, I'm encountering an issue where the gradient class does not display on top of the image. I've even tried using z-index without success.
Does anyone have a solution that doesn't involve placing the background-image in my CSS? Thank you!