add if block to handling oversize page inputed