fix page detect