Comments (3)
Replace the wordpress next_post_link(), etc., but use that as a fallback if paginavi does not exist!
from nebula.
Use:
<?php if ( is_plugin_active('wp-pagenavi/wp-pagenavi.php') ) : ?>
<?php wp_pagenavi(); ?>
<?php else : ?>
<?php
global $wp_query;
$big = 999999999; //An unlikely integer
echo '<div class="wp-pagination">' . paginate_links(array(
'base' => str_replace($big, '%#%', esc_url(get_pagenum_link($big))),
'format' => '?paged=%#%',
'current' => max(1, get_query_var('paged')),
'total' => $wp_query->max_num_pages
)) . '</div>';
?>
<?php endif; ?>
(Updated snippet)
from nebula.
This should appear for search results too (also in the loop).
from nebula.
Related Issues (20)
- Detect page prerender in analytics via Speculation Rules API HOT 5
- Nebula Options Search not returning refined results HOT 2
- Consider indicating the GA4 Property ID somehow HOT 1
- Watch for CSS math functionality types (abs, sign, round, mod, rem, pow, exp...) [🟩 fully supported now] HOT 2
- Use the new WP core method of adding defer/async to JavaScript assets
- Use the CloseWatcher API to track native modal closes in GA
- If the current post is not published, the Nebula admin bar should says "Preview" instead of "View"
- Add a Nebula Option for Related Website Sets?
- Dequeue JS does not with with negated page ID HOT 1
- Customizer customizations
- During Audit Mode, check file sizes of assets and report large files HOT 1
- Sometimes initial load is missing GA4 pageview properties...? HOT 3
- Consider a filter in the Dequeue Styles/Scripts lists
- Detect and store CF7 mail failed and spam submissions HOT 2
- Consider a Nebula CF7 Spam agent behind a Nebula Option HOT 1
- Find a way to show the "Submission" status of the CF7 Submissions submenu by default (instead of "All")
- How can the JS Form Flow data be sent to the PHP CF7 capture data without a hidden form field? HOT 1
- 🔮 PHP 8.3 Upgrade Features/Notes HOT 1
- Plugin conflict: The Events Calendar HOT 4
- Consider a cron that sends digest emails for invalid abandoned forms and mail failed submissions
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nebula.