fixing page counting
doine pagination
merging