Fixed some url problems for switching to multiple pages