This will handle duplicate classname. New classname will be added to $imgClass in line 199.