use url passed to index for base on ajax.