Added more checks
Added URL functionality