ugly version that takes url