You can not use conditional tags on init
Queries are only available after “wp” action hook, so ‘init’ is too early to check for it.
Queries are only available after “wp” action hook, so ‘init’ is too early to check for it.
If you are using “page-template”s you’ll have problems with pagination since pages are not meant to display posts and some people frown upon using page-templates for custom archive display, but it’s sometimes the simplest way. Anyway the solution is 1.) to nullify the global $wpquery 2.) adding ‘paged’ => $paged arg. before displaying your posts…
Disable comments, pings trackbacks etc.. Set media sizes – optionally disable monthly based archiving. Set-up a functionality plugin for the site (add GA code, manage image_sizes, remove query string from sources etc.) . Permalink structure. Move wp-config. Modify wp-config define( ‘WP_POST_REVISIONS’, 3 ); Install favorite plugins Google Maps Easy Yoast SEO Contact Form 7 Create…
If you have a comment in your <head> that says <!– This site is optimized with the Yoast WordPress –> it’s not a big deal for the average user, but if you do not want to openly reveal that you are using WordPress, this is utterly annoying for you. I usually use my own functions…
My navigation menu started disappearing on category pages. First I suspected there was something with the header or menu location, I have double, triple checked everything and I was pulling my hair out trying to find a solution. Turns out, my attempt to order posts by a custom field interfered with the menu. if( ! $query->is_main_query())…
There are mb_strlen() and mb_substr() for multibyte characters however there is no mb_str_word_count. Hence my previous post.
Just use javascript:void(0) instead of # for href You might encounter this error most likely in Firefox Console