Creating image gallery plugin using jquery