Plugin Release: Simple Pagination
Posted: 15 March 2007 12:55 PM   [ Ignore ]  
Lab Assistant
RankRank
Total Posts:  109
Joined  01-12-2006

Although EE is a brilliant CMS I have found it’s pagination support a little lacking, even compared to something as basic as Wordpress. Fortunately the plugin system provides a decent opportunity to make up for any shortfalls and hopefully ‘Simple Pagination’ does just that.

Additional details can be found on my blog but basically this plugin makes it possible to split up entries into an unlimited number of pages by adding a {pagebreak} tag to a message.

Fairly detailed usage info is available in the usage section after you install the plugin and the features are very similar to the standard EE ones so the manual page is probably fairly useful too.

Download Simple Pagination.

Any questions just let me know, I look forward to seeing some examples of the plugin in use (demo here). grin

 Signature 

VayaDesign | EE Design & Development Services
EE Goodies: TealTemplate, Simple Pagination Plugin

Profile
 
 
Posted: 15 March 2007 04:47 PM   [ Ignore ]   [ # 1 ]  
Research Assistant
RankRankRank
Total Posts:  929
Joined  03-25-2005

Way to go! I have a client drooling for article pagination and I never had time to go do it in php. This is great!
Donation will come smile

 Signature 

BKDesign Solutions - Learn XHTML and use Web Standards to build accessible websites that validate

Profile
 
 
Posted: 15 March 2007 06:38 PM   [ Ignore ]   [ # 2 ]  
Moderator
Avatar
RankRankRankRankRankRankRankRank
Total Posts:  31280
Joined  05-14-2004

I can not tell you how nice it will be to have this to point to, it is a fairly oft-requested feature. I hope you’ll submit it to our plugins site as well!

And the main point of this message - thank you. =)

 Signature 
Profile
MSG
 
 
Posted: 16 March 2007 04:56 AM   [ Ignore ]   [ # 3 ]  
Lab Assistant
RankRank
Total Posts:  109
Joined  01-12-2006

Glad to be of use guys!

One thing that I’ve just realised I have forgotten to mention is the optimum placement of any {pagebreak} tags. This only really matters if you’re using the XHTML formatting option but what you want to do is have two linebreaks before and after as if this will ensure that the final <p> tag is closed at the end of the page and likewise that if the next page starts with text then it also begins with a fresh <p> tag.

... end of one page here.

{pagebreak}

Another page gets started here
.

This is required as EE adds any automatic formatting before sending the data to the plugin and as {pagebreak} acts as a divider between pages absolutely anything to the left of the tag will go one page one and anything to the right will be on page two. So if you used the following:

...end of my paragraph.{pagebreak}

New paragraph here.

You’d end up with page one containing:

...end of my paragraph.

And page two containing:

</p>

<
p>New paragraph here.</p>

Which isn’t likely to be very desirable.

 Signature 

VayaDesign | EE Design & Development Services
EE Goodies: TealTemplate, Simple Pagination Plugin

Profile
 
 
Posted: 16 March 2007 08:25 AM   [ Ignore ]   [ # 4 ]  
Research Assistant
RankRankRank
Total Posts:  929
Joined  03-25-2005

... end of one page here.

{pagebreak}

Another page gets started here
.

Does the ee tag above mean it requires the allow EE tags plugin?

 Signature 

BKDesign Solutions - Learn XHTML and use Web Standards to build accessible websites that validate

Profile
 
 
Posted: 16 March 2007 08:31 AM   [ Ignore ]   [ # 5 ]  
Lab Assistant
RankRank
Total Posts:  109
Joined  01-12-2006

No as {exp:pagination} goes in your template, not your entry. You then place your field name inside the {exp:pagination} tags and that ensures the field data is processed accordingly.

Hopefully that makes sense, but basically no, all that’s required is the plugin itself.

 Signature 

VayaDesign | EE Design & Development Services
EE Goodies: TealTemplate, Simple Pagination Plugin

Profile
 
 
Posted: 16 March 2007 08:44 AM   [ Ignore ]   [ # 6 ]  
Research Assistant
RankRankRank
Total Posts:  929
Joined  03-25-2005

end of my paragraph.{pagebreak}
New paragraph here.

? In template?
What determines where the page break then? Paragraphs or? Sorry if I’m being dense, just woke up
(thats my excuse and I’m stickin to it) lol
ok, with some coffee it all came together.
(Note: add to docs, “have 2 coffee, then read instructions")
Well done!

 Signature 

BKDesign Solutions - Learn XHTML and use Web Standards to build accessible websites that validate

Profile
 
 
Posted: 16 March 2007 08:50 AM   [ Ignore ]   [ # 7 ]  
Lab Assistant
RankRank
Total Posts:  109
Joined  01-12-2006

{pagebreak} tags split up the pages, but you don’t need the EE tags plugin. Call it black magic if you like. wink

All the info you need to use the plugin is available in your control panel’s plugin manager after installing it. If after having a look at that you’re still unsure then just let me know.

 Signature 

VayaDesign | EE Design & Development Services
EE Goodies: TealTemplate, Simple Pagination Plugin

Profile
 
 
Posted: 16 March 2007 10:27 AM   [ Ignore ]   [ # 8 ]  
Research Scientist
Avatar
RankRankRankRankRankRank
Total Posts:  5958
Joined  08-04-2002

Very handy!!! Thanks!!!

Profile
 
 
Posted: 18 March 2007 08:36 AM   [ Ignore ]   [ # 9 ]  
Lab Assistant
Avatar
RankRank
Total Posts:  207
Joined  11-04-2002

Awesome, thank you so much for this plugin!! I have been looking for something like this for ages! :D

 Signature 

erinshore.net | stillburning.com | fever of fate

Profile
 
 
Posted: 18 March 2007 12:05 PM   [ Ignore ]   [ # 10 ]  
Lab Assistant
RankRank
Total Posts:  163
Joined  07-07-2005

Oh, excellent!

 Signature 

i have a (redesigned) website. it’s still sort of blue, but mostly not...

Profile
 
 
Posted: 04 February 2008 02:03 PM   [ Ignore ]   [ # 11 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  602
Joined  06-29-2005

I have featured the use of this excellent solution in my EE Wiki entry - Automatic Spanning of Book Length Entries Across Multiple Pages. It was the most important part of making this all work!

So, Thanks Thanks Thanks!

Terry

Profile
 
 
Posted: 04 February 2008 07:05 PM   [ Ignore ]   [ # 12 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  524
Joined  08-31-2005

Dom.S:
From your comment above, were you saying it doesn’t close open tags? Anyway to modify the plugin to close open tags on the ends of pages and create any beginning tags for those with only closing tags?

I’m just thinking of this from the perspective of me creating a site for an end user. So while we all may be alert enough to make sure all tags are closed before we insert the {pagebreak}, some end users are not that knowledgeable. Having unclosed/unopened tags would certainly cause some issues with page display.

Profile
 
 
Posted: 04 February 2008 08:10 PM   [ Ignore ]   [ # 13 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  602
Joined  06-29-2005

He was not saying it left tags open.

The {page_break} things are not “tags” like go in templates, but rather are triggers that go into the body text itself, on the publish page.

Terry

Profile
 
 
Posted: 04 February 2008 08:16 PM   [ Ignore ]   [ # 14 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  524
Joined  08-31-2005

correct. i am aware that the {page_break} itself isn’t a tag. I’m talking about when there are tags within the body (which is what he was saying as well). So if you put a {page_break} in the middle of a bolded section. There will be no </strong> on the first page and only a </strong> on the next page. That could be a problem.

And while it is easy to say “make sure all of your tags are closed”. An end user who has no idea about html won’t have a clue what that means...and will more than likely not do it correctly.

Profile
 
 
Posted: 04 February 2008 08:41 PM   [ Ignore ]   [ # 15 ]  
Research Assistant
Avatar
RankRankRank
Total Posts:  602
Joined  06-29-2005

Oh yes, I see what you are saying now. That could become a problem, indeed. Perhaps some php string function involved in the module could scan for open/closing tag pairs?

Or simply insert line breaks in the page, before and after the {page_break} tag?

This may not be as bad as it seems (from above):

This only really matters if you’re using the XHTML formatting option but what you want to do is have two linebreaks before and after as if this will ensure that the final <p> tag is closed at the end of the page and likewise that if the next page starts with text then it also begins with a fresh <p> tag.

It doesn’t seem to apply to other tags, just the EE generated paragraph tags added in XHTML formatting.

Terry

Profile
 
 
Posted: 28 May 2008 06:33 PM   [ Ignore ]   [ # 16 ]  
Summer Student
Avatar
Total Posts:  20
Joined  02-10-2008

Genius! You just saved me countless hours!!!!!

Profile
 
 
Posted: 19 June 2008 07:20 AM   [ Ignore ]   [ # 17 ]  
Grad Student
Avatar
Rank
Total Posts:  76
Joined  04-25-2008

YES! I love you for creating this!!

Gonna try out the plugin now. hahaha

Profile
 
 
   
 
 
Post Marker Legend
New Topic New posts Hot Topic Hot Topic with new posts New Poll New Poll Moved Topic Moved Topic Sticky Topic Sticky topic
Old Topic No new posts Hot Old Topic Hot Topic with no new posts Old Poll Old Poll Closed Topic Closed Topic Announcement Announcements
Theme
Change Theme
Visitor Statistics
The most visitors ever was 1149, on July 16, 2007 10:33 AM
Total Registered Members: 61056 Total Logged-in Users: 28
Total Topics: 73864 Total Anonymous Users: 18
Total Replies: 398419 Total Guests: 465
Total Posts: 472283    
Members ( View Memberlist )
Newest Members:  Schottec2kmeenazterjinFuadgeorge_k_alliskhalidmhamoodStewart RoonieMarufjakedahn