Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

splitting html file

 
Taggu Gupta
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In our application we load html files. But, sometime because of the size of the html file the loading takes a lot of time and there is user frustration because of this. Can we break the huge html file into parts and then load it part by part. What is the best way of doing this.
 
Ulf Dittmer
Rancher
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Why are the files so large? There's a limit to what humans can process in one go. Why not serve smaller pages containing less information, and then add a pagination feature so that users can navigate between pages?
 
Taggu Gupta
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In our application we convert word,excel,pdf, etc documents to html files for viewing in the browser. For e.g if the excel file is huge then it is converted to a huge html file. This how we get a huge html file. My question what technology/technique can I use to split this large html file into smaller blocks and then load it as a page.
 
Ulf Dittmer
Rancher
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That's what pagination is: to break a document into smaller pieces (for example pages of a document, that's where the word originates), and serve those individually. Word and PDF in particular have a natural "page", for spreadsheets it depends on its internal structure.
 
Taggu Gupta
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for helping. But, how do i actually split this html file and then page it . Can you provide a small code so I can understand it much better or maybe point me to some place which has this.
 
Ulf Dittmer
Rancher
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How are you converting documents to HTML pages? Some library? That's where you would split it into pieces.
 
Taggu Gupta
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, I'm using a third party library which converts this into an html file. So, I can only do post-processing on the already generated html file. But, how do i split and then re-assemble this as a page in the client code. Some pointers would be useful.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic