I'm using a template with the Responsive layout. I have a banner on the right side of a website. What I'm doing is that by scrolling the page the banner accompanies the page. When I lower the window, the banner goes over the content. What he wanted to do, was the banner disappear when the window was dimmed. The code below is what makes the banner follow the page. How do I disappear the banner if the window is smaller?
<style>
#getFixed { padding: 100px 0px 0 0px; margin: 10px; z-index: 50000; }
</style>
<script>
function fixDiv() {
var $cache = $('#getFixed');
if ($(window).scrollTop() > 350)
$cache.css({'position': 'fixed', 'top': '10px'});
else
$cache.css({'position': 'relative', 'top': 'auto'});
}
$(window).scroll(fixDiv);
fixDiv();
</script>
<div id="getFixed"><img src="banner.png" width="220"></div>