mirror of
https://gh.wpcy.net/https://github.com/mainwp/Code-Snippets-Functions.git
synced 2026-05-01 11:52:25 +08:00
Exclude Jetpack lazy loading by POST ID, slug or title. https://developer.jetpack.com/hooks/lazyload_is_enabled/
8 lines
214 B
Text
8 lines
214 B
Text
add_filter( 'lazyload_is_enabled', 'jp_lazyload_exclude', 15 );
|
|
function jp_lazyload_exclude() {
|
|
if ( is_page( array( 12, 'slug', 'Title' ) ) ) {
|
|
return false;
|
|
} else {
|
|
return true;
|
|
}
|
|
}
|