generalising post/refresh urls