added support for differently formated pages