summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJen Lampton2012-12-17 01:32:41 (GMT)
committer Jen Lampton2012-12-17 01:32:41 (GMT)
commit73998c597070079f18085686dac29e28adcc4be9 (patch)
treee78bb79353ba86abfa02827a04a6254a5b714b1c
parent92e4ec4283631c89a1fc723ef670d3b88d991246 (diff)
Issue #470476 by jenlampton: Provide a theme function for output HTML
-rw-r--r--paging.module16
1 files changed, 15 insertions, 1 deletions
diff --git a/paging.module b/paging.module
index 165dec4..e544cba 100644
--- a/paging.module
+++ b/paging.module
@@ -28,6 +28,7 @@ function paging_theme() {
'paging_drop_down' => array('tags' => NULL, 'limit' => NULL, 'element' => NULL, 'parameters' => NULL, 'quantity' => NULL),
// Helper theme function to generates the select list for drop down pager.
'paging_drop_down_option' => array('url_chunk' => NULL, 'page_name' => NULL, 'page_no' => NULL, 'selected' => NULL),
+ 'pager_wrapper' => array('output' => NULL),
);
}
@@ -645,7 +646,7 @@ function paging_pager_style($node = NULL, $element = NULL) {
// Decode the comma entity.
$output = str_replace('%2C', ',', theme($theme_widget, NULL, 1, $element, array(), 9, $node->page_names));
- return '<div class="links">' . $output . '</div>';
+ return theme('pager_wrapper', $output);
}
/**
@@ -926,3 +927,16 @@ function paging_wysiwyg_include_directory($type) {
return 'wysiwyg';
}
}
+
+/**
+ * Format the wrapper around pager links.
+ *
+ * @param $output
+ * The themed pager links
+ *
+ * @return
+ * An HTML string.
+ */
+function theme_pager_wrapper($output){
+ return '<div class="links">' . $output . '</div>';
+} \ No newline at end of file