added option to choose method in ajax load