From c3b24e200566b11e80f96f8186dbe5eab6241d72 Mon Sep 17 00:00:00 2001 From: PayBas Date: Thu, 29 May 2014 23:28:22 +0200 Subject: [ticket/12613] Improved pagination PHPBB3-12613 --- phpBB/styles/prosilver/template/forum_fn.js | 27 +++++------ phpBB/styles/prosilver/template/pagination.html | 55 +++++++++++++++------- .../styles/prosilver/template/viewforum_body.html | 8 ++-- .../styles/prosilver/template/viewtopic_body.html | 8 ++-- 4 files changed, 58 insertions(+), 40 deletions(-) (limited to 'phpBB/styles/prosilver/template') diff --git a/phpBB/styles/prosilver/template/forum_fn.js b/phpBB/styles/prosilver/template/forum_fn.js index fa838fde19..5d2382c4dd 100644 --- a/phpBB/styles/prosilver/template/forum_fn.js +++ b/phpBB/styles/prosilver/template/forum_fn.js @@ -25,20 +25,12 @@ function popup(url, width, height, name) { /** * Jump to page */ -function jumpto(item) { - if (!item || !item.length) { - item = $('a.pagination-trigger[data-lang-jump-page]'); - if (!item.length) { - return; - } - } +function jumpto(form) { - var jump_page = item.attr('data-lang-jump-page'), - on_page = item.attr('data-on-page'), - per_page = item.attr('data-per-page'), - base_url = item.attr('data-base-url'), - start_name = item.attr('data-start-name'), - page = prompt(jump_page, on_page); + var page = $(form).find("input[name='page-number']").val(), + per_page = $(form).find("input[name='per-page']").val(), + base_url = $(form).find("input[name='base-url']").val(), + start_name = $(form).find("input[name='start-name']").val(); if (page !== null && !isNaN(page) && page == Math.floor(page) && page > 0) { if (base_url.indexOf('?') === -1) { @@ -363,9 +355,16 @@ function parse_document(container) /** * Pagination */ - container.find('a.pagination-trigger').click(function() { + container.find('form.page-jump-form').submit(function(event) { + event.preventDefault(); jumpto($(this)); }); + + container.find('.pagination-trigger').click(function() { + $input = $(this).parent().find("input[name='page-number']"); + + setTimeout(function() { $input.focus(); },100); + }); /** * Dropdowns diff --git a/phpBB/styles/prosilver/template/pagination.html b/phpBB/styles/prosilver/template/pagination.html index e27a90900a..8b8631ce26 100644 --- a/phpBB/styles/prosilver/template/pagination.html +++ b/phpBB/styles/prosilver/template/pagination.html @@ -1,18 +1,37 @@ - - {PAGE_NUMBER} • - - {PAGE_NUMBER} • - - + diff --git a/phpBB/styles/prosilver/template/viewforum_body.html b/phpBB/styles/prosilver/template/viewforum_body.html index c747dd01f5..51aaeb937e 100644 --- a/phpBB/styles/prosilver/template/viewforum_body.html +++ b/phpBB/styles/prosilver/template/viewforum_body.html @@ -59,11 +59,11 @@ @@ -233,11 +233,11 @@ diff --git a/phpBB/styles/prosilver/template/viewtopic_body.html b/phpBB/styles/prosilver/template/viewtopic_body.html index fb0b9733e7..2133f9a21a 100644 --- a/phpBB/styles/prosilver/template/viewtopic_body.html +++ b/phpBB/styles/prosilver/template/viewtopic_body.html @@ -51,11 +51,11 @@ @@ -352,11 +352,11 @@ -- cgit v1.2.1 From 140ecf1c98175ce6984968d10c35ce80fe927526 Mon Sep 17 00:00:00 2001 From: PayBas Date: Fri, 30 May 2014 01:13:23 +0200 Subject: [ticket/12613] Removed all previous_page / next_page text links PHPBB3-12613 --- phpBB/styles/prosilver/template/mcp_forum.html | 2 -- phpBB/styles/prosilver/template/mcp_logs.html | 2 -- phpBB/styles/prosilver/template/mcp_notes_user.html | 2 -- phpBB/styles/prosilver/template/mcp_queue.html | 2 -- phpBB/styles/prosilver/template/mcp_reports.html | 2 -- phpBB/styles/prosilver/template/memberlist_body.html | 2 -- phpBB/styles/prosilver/template/search_results.html | 2 -- phpBB/styles/prosilver/template/ucp_attachments.html | 2 -- phpBB/styles/prosilver/template/ucp_pm_viewfolder.html | 2 -- phpBB/styles/prosilver/template/viewforum_body.html | 2 -- phpBB/styles/prosilver/template/viewonline_body.html | 6 ------ phpBB/styles/prosilver/template/viewtopic_body.html | 8 +++----- 12 files changed, 3 insertions(+), 31 deletions(-) (limited to 'phpBB/styles/prosilver/template') diff --git a/phpBB/styles/prosilver/template/mcp_forum.html b/phpBB/styles/prosilver/template/mcp_forum.html index 4a8c4c5de9..02c6edb05b 100644 --- a/phpBB/styles/prosilver/template/mcp_forum.html +++ b/phpBB/styles/prosilver/template/mcp_forum.html @@ -95,8 +95,6 @@
- {L_NEXT} - {L_PREVIOUS} diff --git a/phpBB/styles/prosilver/template/mcp_logs.html b/phpBB/styles/prosilver/template/mcp_logs.html index b930bbbcc6..0aba36b8fd 100644 --- a/phpBB/styles/prosilver/template/mcp_logs.html +++ b/phpBB/styles/prosilver/template/mcp_logs.html @@ -54,8 +54,6 @@
- {L_NEXT} - {L_PREVIOUS} diff --git a/phpBB/styles/prosilver/template/mcp_notes_user.html b/phpBB/styles/prosilver/template/mcp_notes_user.html index 9b6c9b2667..127cf7cb08 100644 --- a/phpBB/styles/prosilver/template/mcp_notes_user.html +++ b/phpBB/styles/prosilver/template/mcp_notes_user.html @@ -95,8 +95,6 @@
- {L_NEXT} - {L_PREVIOUS} diff --git a/phpBB/styles/prosilver/template/mcp_queue.html b/phpBB/styles/prosilver/template/mcp_queue.html index 461d5982db..4cee8c0094 100644 --- a/phpBB/styles/prosilver/template/mcp_queue.html +++ b/phpBB/styles/prosilver/template/mcp_queue.html @@ -73,8 +73,6 @@
- {L_NEXT} - {L_PREVIOUS} diff --git a/phpBB/styles/prosilver/template/mcp_reports.html b/phpBB/styles/prosilver/template/mcp_reports.html index ffa82d5e0e..62edf22958 100644 --- a/phpBB/styles/prosilver/template/mcp_reports.html +++ b/phpBB/styles/prosilver/template/mcp_reports.html @@ -79,8 +79,6 @@
- {L_NEXT} - {L_PREVIOUS} diff --git a/phpBB/styles/prosilver/template/memberlist_body.html b/phpBB/styles/prosilver/template/memberlist_body.html index 7623fbe38b..9891ec71ce 100644 --- a/phpBB/styles/prosilver/template/memberlist_body.html +++ b/phpBB/styles/prosilver/template/memberlist_body.html @@ -140,8 +140,6 @@
- {L_PREVIOUS} - {L_NEXT} diff --git a/phpBB/styles/prosilver/template/search_results.html b/phpBB/styles/prosilver/template/search_results.html index 0043da4507..9e770a2d66 100644 --- a/phpBB/styles/prosilver/template/search_results.html +++ b/phpBB/styles/prosilver/template/search_results.html @@ -164,8 +164,6 @@
- {L_PREVIOUS} - {L_NEXT} diff --git a/phpBB/styles/prosilver/template/ucp_attachments.html b/phpBB/styles/prosilver/template/ucp_attachments.html index 4731683a80..587e3eaed5 100644 --- a/phpBB/styles/prosilver/template/ucp_attachments.html +++ b/phpBB/styles/prosilver/template/ucp_attachments.html @@ -51,8 +51,6 @@
- {L_NEXT} - {L_PREVIOUS} diff --git a/phpBB/styles/prosilver/template/ucp_pm_viewfolder.html b/phpBB/styles/prosilver/template/ucp_pm_viewfolder.html index b081c14498..d51676b5aa 100644 --- a/phpBB/styles/prosilver/template/ucp_pm_viewfolder.html +++ b/phpBB/styles/prosilver/template/ucp_pm_viewfolder.html @@ -123,8 +123,6 @@
- {L_PREVIOUS} - {L_NEXT} diff --git a/phpBB/styles/prosilver/template/viewforum_body.html b/phpBB/styles/prosilver/template/viewforum_body.html index 51aaeb937e..1cc6f93bab 100644 --- a/phpBB/styles/prosilver/template/viewforum_body.html +++ b/phpBB/styles/prosilver/template/viewforum_body.html @@ -208,8 +208,6 @@
- {L_PREVIOUS} - {L_NEXT} diff --git a/phpBB/styles/prosilver/template/viewonline_body.html b/phpBB/styles/prosilver/template/viewonline_body.html index 553e322f92..a8fb6424b6 100644 --- a/phpBB/styles/prosilver/template/viewonline_body.html +++ b/phpBB/styles/prosilver/template/viewonline_body.html @@ -47,12 +47,6 @@ - -
- {L_PREVIOUS}{L_PREVIOUS}{L_NEXT}{L_NEXT} -
- -

{L_LEGEND}{L_COLON} {LEGEND}

- + + + + -
+