fixed auto page generation stuff