Building a simple image slider/gallery. I have some simple replace code, nothing fancy.
<script>
$(".imgt").click(function(){
var newsrc = (this).attr("src");
$("#imgb").attr("src","newsrc");
});
</script>
It’s the var and the call to the var that I’m unsure about.
Do it like that: