In my HTML file, there is a main div container with two nested divs inside it. Each of these inner divs has been assigned separate ids for content placement. By implementing a functionality that changes the background image of the parent div upon clicking a link inside the second nested div, I encountered an issue where setting the background-size property to cover didn't display the entire image on the screen. Below is the snippet of code where I attempted to adjust the background size:
<script>
$(document).ready(function(){
//autoOpen: false,
$(".span12").css('background-image','url(../images/assorting_2.jpg)','background-size','100%');
</script>
I would have included screenshots to demonstrate the problem, but unable to do so due to insufficient points in this platform.