• Resolved John Webber

    (@bilion)


    Hello,

    Thank you for this wonderful plugin.

    1) Please, add the option to set rules for Author archives.

    2)
    Under archives, we can set each Category or Tag to have it’s own rules.
    This is not ideal if the authors or vendors are adding new categories and tags.
    You have to go and add rules for each manually.
    It would be great if we could set global rules for archives: Category, Tag and Author.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter John Webber

    (@bilion)

    Some additional info and issues…

    I’m using a Full Site Editing theme.
    Besides templates for the Author archive, Date archive, we also have the 404 page and Search results page.

    None of these templates / pages can be optimized with the FreeSoul plugin.

    Maybe there are other pages and templates as well. I haven’t tested everything.

    Plugin Author Jose

    (@giuse)

    Hi @bilion

    thank you very much for your suggestions.

    1) This is already in the roadmap for the PRO version.
    With the free version, I suggest you use Custom URLs => Frontend URLs.
    Usually, the author archive pages look like https://your-website.com/author/author-name/.
    You can match this kind of URL with */author/*.

    2) This is also in the roadmap. Maybe it will be a free feature, but it will require time, and I can’t say when it will be ready.
    Also for this kind of URL, many times you can use Custom URLs => Frontend URLs

    About your second thread. At the moment you can’t disable plugins on the 404 page, but you can do it for the search results page. See this picture: https://freesoul-deactivate-plugins.com/wp-content/uploads/2021/08/fdp-disable-plugins-on-search-results-page.png. Have you tried it and doesn’t work for you?

    Without doing any tricks you can’t disable plugins for the 404 page because WP redirects to the 404 page only after all plugins are loaded. The code of FDP would run after all plugins are loaded.

    But you could create a custom redirection for the 404 error, for instance, something that looks like https://your-website.com?e404=true, or whatever query argument you like, and then you can use the same argument in Custom URLs => Frontend URLs. In this case, you would be able to match the 404 page with *e404=true

    You can customize the 404 URL with this code:

    add_action( 'template_redirect',function(){
    	$custom_arg = 'e404';
      if( !isset( $_GET[$custom_arg] ) && isset( $_SERVER['HTTP_HOST'] ) && isset( $_SERVER['REQUEST_URI'] ) && is_404() ){
    		$uri = esc_url( $_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI'] );
        wp_redirect( add_query_arg( $custom_arg,'true',$uri ) );
        exit();
      }
    } );

    If you add the code above to the functions.php of your child theme, or to a functional plugin, then the error page will have this URL:

    https://your-domain.com?e404=true

    Replace e404 with whatever you like. It’s important you use the same string in Custom URLs => Frontend URLs

    I hope it helps.

    • This reply was modified 1 year, 9 months ago by Jose.
    • This reply was modified 1 year, 9 months ago by Jose.
    • This reply was modified 1 year, 9 months ago by Jose.
    Plugin Author Jose

    (@giuse)

    @bilion be careful, I’ve edited my thread because the code that I suggested before needed to be corrected.

    Thread Starter John Webber

    (@bilion)

    Hi @giuse,

    Thank you for the help and the info abut the roadmap.

    I’ll put the code to use.

    Don’t know why I didn’t see the Search page. But, it’s there and it will probably work.

    Plugin Author Jose

    (@giuse)

    Hi @bilion

    Sorry for my late answer. You are welcome! Do you still need help?

    I’m going to close this thread because I’m sorting out the cases, and I assume you have solved the issue, but if you still need help don’t hesitate to open it again and reply.

    Have a great day!

    Jose

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Author Archive and Global Rules For Archives’ is closed to new replies.