Force goto-page event parameters to be integers

This avoids problems when external pages pass in strings and JavaScript
causes "123" + 1 to be "1231" rather than "124". Since this is easy to
get wrong, the event handler will convert everything.