diff options
author | Michael Bien <[email protected]> | 2010-09-05 03:22:00 +0200 |
---|---|---|
committer | Michael Bien <[email protected]> | 2010-09-05 03:22:00 +0200 |
commit | 315ef0788ece29f35e4f69279e571b33dd94776f (patch) | |
tree | f89f3c6d1d6c40999aec71de294ca96cabb125b1 | |
parent | 710cefdd380882fcf73d87f580650826274fbd99 (diff) |
pagination for streams and planet.
-rw-r--r-- | planet2/config/pager-template.html | 17 | ||||
-rw-r--r-- | planet2/config/planet-config.xml | 4 | ||||
-rw-r--r-- | planet2/config/planet-template.html | 6 | ||||
-rw-r--r-- | planet2/config/stream-config.xml | 19 | ||||
-rw-r--r-- | planet2/config/stream-template.html | 8 | ||||
-rw-r--r-- | planet2/update-planet.sh | 1 | ||||
-rw-r--r-- | planet2/update-stream.sh | 1 | ||||
-rwxr-xr-x | style.css | 1 |
8 files changed, 37 insertions, 20 deletions
diff --git a/planet2/config/pager-template.html b/planet2/config/pager-template.html new file mode 100644 index 0000000..301a7ff --- /dev/null +++ b/planet2/config/pager-template.html @@ -0,0 +1,17 @@ +<table class="centered"> + <tr> + <td> + <#if prev??> + « <a href="${prev}">Previous Page</a> | + </#if> + </td> + <td> + <a href="${filename}">Page (${page} of ${pages})</a> + </td> + <td> + <#if next??> + | <a href="${next}">Next Page</a> » + </#if> + </td> + </tr> +</table>
\ No newline at end of file diff --git a/planet2/config/planet-config.xml b/planet2/config/planet-config.xml index fddb1ba..ce473fe 100644 --- a/planet2/config/planet-config.xml +++ b/planet2/config/planet-config.xml @@ -4,7 +4,9 @@ <planet title="Planet JogAmp" description="JogAmp Aggregated Feeds" author="Hungry Harry" - maxEntries="30" + maxEntries="80" + maxEntriesPerPage="15" + name="index" link="http://jogamp.org/planet"> <feed>rss_2.0</feed> <template>/srv/www/jogamp.org/planet2/config/planet-template.html</template> diff --git a/planet2/config/planet-template.html b/planet2/config/planet-template.html index 9af9d2b..1bbe69a 100644 --- a/planet2/config/planet-template.html +++ b/planet2/config/planet-template.html @@ -103,6 +103,12 @@ ${entry.content}<br/> <br/> </#list> + + <br/> + <div class="centered"> + <#include "pager-template.html"> + </div> + </div> </div> diff --git a/planet2/config/stream-config.xml b/planet2/config/stream-config.xml index 22822c8..f2305ce 100644 --- a/planet2/config/stream-config.xml +++ b/planet2/config/stream-config.xml @@ -3,30 +3,17 @@ <planet title="JogAmp Streams" description="JogAmp Aggregated Feeds" author="Hungry Harry" - maxEntries="50" + maxEntries="100" + maxEntriesPerPage="20" + name="index" link="http://jogamp.org/stream/"> <feed>rss_2.0</feed> <template>/srv/www/jogamp.org/planet2/config/stream-template.html</template> <output>/srv/www/jogamp.org/stream</output> </planet> -<!-- - <feed name="vimeo" url="http://vimeo.com/tag:jogl/rss"/> - --> <feed name="demoscenepassivist" url="http://gdata.youtube.com/feeds/base/users/DemoscenePassivist/uploads?alt=rss&v=2&orderby=published&client=ytapi-youtube-profile"/> <feed name="demoscenepassivist-favorites" url="http://gdata.youtube.com/feeds/api/users/DemoscenePassivist/favorites?orderby=updated"/> - <template keyword="vimeo" idpattern="http://vimeo.com/([0-9]+)"> -<![CDATA[ - <object width="400" height="320"> - <param name="allowfullscreen" value="true" /> - <param name="allowscriptaccess" value="always" /> - <param name="movie" value="http://vimeo.com/moogaloop.swf?clip_id=#id#&server=vimeo.com&show_title=1&show_byline=1&show_portrait=0&color=&fullscreen=1" /> - <embed src="http://vimeo.com/moogaloop.swf?clip_id=#id#&server=vimeo.com&show_title=1&show_byline=1&show_portrait=0&color=&fullscreen=1" - type="application/x-shockwave-flash" allowfullscreen="true" allowscriptaccess="always" width="400" height="320"> - </embed> - </object> -]]> - </template> <template keyword="youtube" idpattern="http://www.youtube.com/watch\?v=([^&]+)" descriptionfilter="<span>(.*)</span>"> <![CDATA[ <a href="http://www.youtube.com/watch?v=#id#"><img src="http://img.youtube.com/vi/#id#/1.jpg" alt="Youtube Video Thumbnail 1"/></a> diff --git a/planet2/config/stream-template.html b/planet2/config/stream-template.html index 7c42af2..7c316e7 100644 --- a/planet2/config/stream-template.html +++ b/planet2/config/stream-template.html @@ -82,7 +82,7 @@ <td class="streams_thumbs"> ${entry.player} </td> - <td class="stream_stext"> + <td class="streams_text"> <b>${entry.title}</b><br> ${entry.filteredDescription} </td> @@ -90,6 +90,12 @@ </table> </div> </#list> + +<br/> +<div class="centered"> +<#include "pager-template.html"> +</div> + </div> </div> <div id="footer"> diff --git a/planet2/update-planet.sh b/planet2/update-planet.sh index 9b10163..6cf31f6 100644 --- a/planet2/update-planet.sh +++ b/planet2/update-planet.sh @@ -1,3 +1,2 @@ java -jar HungryHarry-SNAPSHOT-jar-with-dependencies.jar /srv/www/jogamp.org/planet2/config/planet-config.xml -mv ../planet/planet.html ../planet/index.html diff --git a/planet2/update-stream.sh b/planet2/update-stream.sh index 9e26d92..375fa86 100644 --- a/planet2/update-stream.sh +++ b/planet2/update-stream.sh @@ -1,3 +1,2 @@ java -jar HungryHarry-SNAPSHOT-jar-with-dependencies.jar /srv/www/jogamp.org/planet2/config/stream-config.xml -mv ../stream/planet.html ../stream/index.html @@ -28,6 +28,7 @@ body {padding:15px 20px; margin:0; background: #f5f5f5; font-family: "Trebuchet .rss {background:url(images/feed-icon-10x10.png) no-repeat scroll 2px 50% !important; padding:0px 0px 0px 15px;} .fill {margin-right:0 !important;} +.centered {margin-left: auto; margin-right: auto;} #sidebar {width:160px; height: auto; float: right; padding:0 30px 30px 30px; } #sidebar h3 {font-size:17px; font-weight:normal; margin:20px 0 5px 0;} |