- Books will be
{books:[book_id,book_name,book_descr/rating/author/etc]}
into the database (tables like {books:[book_id,book_name,book_descr/rating/author/etc]}
and {book_pages:[book_id,page_num,text]}
) - We show the description, from there a reference like
books.php?book_id=15
- When you click on the page number to load the desired page by Ajax
Note - there are many functions in the internet that break text into words / symbols. To fill, you need to catch the file, fill in the info about the book (the books table), and break the text into ~ 1800 characters by words (this is A4) and push them page by page into the book_pages table.
PS: Ready you are unlikely to write, it is not 3 lines.
ZZY: I advise you to look for a ready implementation, this may well be.