Need help with custom rewrite rule
pagename is for the page post type, if you are trying to pass the slug for the presskit post type, remove post_type and pagename and just set presskit=$matches[1] instead.
pagename is for the page post type, if you are trying to pass the slug for the presskit post type, remove post_type and pagename and just set presskit=$matches[1] instead.
ModRewrite not working properly
Have you thought of making post type, taxonomy, terms? If you do so, it will be a lot easier for you to code and get the above urls. If any confusion, let me know.
It should work with this lines which simply remove the .php from files that end with .php: RewriteCond %{REQUEST_FILENAME}.php -f RewriteRule !.*\.php$ %{REQUEST_FILENAME}.php [QSA,L]
So the problem was redirect_guess_404_permalink was detecting a 404 error and ‘guessed’ /members/blog to be /blog My hacky solution was to hook into the status error check (Stop WordPress from “guessing” redirects for nonexistent URLs) and if URL parts match then unset the guessed solution function blog_no_redirect_guess_404_permalink( $header ){ global $wp_query; if( is_404() ) { … Read more
Pagination appearing twice in URL after rewrite
Blog List Page 404 With Custom Post Type Rewriting to Blog Parent
Milo’s advice set Mansur Khan in the right direction: In your rewrite_rules_array filter you can look at $rules and see everything you’d need to duplicate. There are a lot of them- single posts, author archives, date archives, taxonomy archives, post formats, attachments, plus pagination and feeds for all of them. The updated, working code: add_filter( … Read more
I found where problem was – i can’t set other year. All i needed to do is to rename year parameter to something else – for example my_year.
You don’t need to create a folder. And create a file inside your theme with starting content of following one <?php /* Template Name: Mail Page */ // here your mail page content. ?> Now goto backend and pages-> Add New. Title your page and select a Template Mail Page. Now you can write your … Read more