wp-pagenavi support #179

Closed
tarampampam opened this Issue Feb 26, 2015 · 4 comments

Projects

None yet

3 participants

@tarampampam

Great theme! Maybe you add wp-pagenavi plugin supports? My example:

./style.css, add this:

.wp-pagenavi {
  text-align:center;
}

.wp-pagenavi .page,
.wp-pagenavi .current,
.wp-pagenavi .nextpostslink,
.wp-pagenavi .previouspostslink,
.wp-pagenavi .extend,
.wp-pagenavi .last,
.wp-pagenavi .first {
  background-color:#555;
  color:#eee;
  display: inline-block;
  padding:8px 15px;
  margin:0 1px;
  min-width: 20px;
}

.wp-pagenavi .current,
.wp-pagenavi a:hover,
.wp-pagenavi a:focus,
.wp-pagenavi a:active {
  transition: background-color 0.1s linear;
  text-decoration: none;
  background-color:#333;
}

./inc/template-tags.php, modify this:

...
function independent_publisher_content_nav( $nav_id ) {
  global $wp_query, $post;
...

to this:

...
function independent_publisher_content_nav( $nav_id ) {
  $nav_class = 'site-navigation paging-navigation';
  if ( is_single() )
    $nav_class = 'site-navigation post-navigation';
  if(function_exists('wp_pagenavi')) {
    echo('<nav role="navigation" id="'.$nav_id.'" class="'.$nav_class.'">');
    wp_pagenavi();
    echo('</nav>');
    return;
  }
  global $wp_query, $post;
...

Preview:
screenshot_1

@raamdev raamdev added the enhancement label Feb 26, 2015
@raamdev raamdev added this to the Next Release milestone Feb 26, 2015
@raamdev
Owner
raamdev commented Feb 26, 2015

@tarampampam Thanks so much for the feature request! I'll mark this as something to add to the next release. :-)

@manishsuwal
Contributor

This is exactly what I was looking for, but built in the theme itself which
we can control through the customizer.

On Thu, Feb 26, 2015 at 11:43 PM, Raam Dev notifications@github.com wrote:

@tarampampam https://github.com/tarampampam Thanks so much for the
feature request! I'll mark this as something to add to the next release.
:-)


Reply to this email directly or view it on GitHub
#179 (comment)
.

Manish Suwal 'Enwil'

blog http://enwil.com | facebook account
http://www.facebook.com/manishsuwal | facebook page
http://www.facebook.com/pages/Enwilcom/266258376816540?ref=ts | twitter
http://www.twitter.com/manishsuwal | google+
https://plus.google.com/118039990517392424384

@raamdev raamdev added a commit that closed this issue May 2, 2016
@raamdev Add support for WP-PageNavi plugin
Resolves #179
ff44b7a
@raamdev raamdev closed this in ff44b7a May 2, 2016
@raamdev
Owner
raamdev commented May 2, 2016

Support for WP-PageNavi has been added:

Screenshot of WP-PageNavi used with Independent Publisher theme

@raamdev
Owner
raamdev commented May 2, 2016

Next Release Changelog:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment