function fot loading script added