Load script contents when data has been retrieved