I have a function entitled changeSize()
which i want to change the size of the div / span etc that it is used next to. Here is my code:
function changeSize(width, height) {
$(this).css('height', height);
$(this).css('width', width);
}
$('#square').changeSize(200, 200);
I presumed that the changeSize would replace (this) with ('#square')
because it is used next to the function - but it doesn't