WordPress.org

Forums

WP-Filebase Download Manager
No custom post type, What else? (3 posts)

  1. stefanluk
    Member
    Posted 1 year ago #

    Hi,

    I want to check if a page is using the WP File Base plugin. If so, I want to do stuff...

    I allways did such thing with an if statement checking the custom post type. But I can't seem to find any for WP File Base.

    Anyone knows what I have to do, to accomplish something similar?

    Thanks,
    Stefan

    https://wordpress.org/plugins/wp-filebase/

  2. Fabian
    Member
    Plugin Author

    Posted 1 year ago #

    I'm not sure if I get you right.
    Do you need a template variable for file templates containing the current post type?
    Or do you need a custom post type for files? If so, take a look at WP-Filebase Pro, it generates File Pages as a custom post type.

    Regards
    Fabian

  3. stefanluk
    Member
    Posted 1 year ago #

    I don't need single File Pages. Let me try to explain myself a little better.

    The download section of my site goes 4 category levels deep.

    I want to use the category list widget in my sidebar to show to first 3 levels. When you click on level 1, it expands and shows all level 2 categories. When you click level 2, it expands and shows all level 3 categories. (I can do this myself).

    But when you click on a 3rd level category, I want the page to show ALL the downloads, sorted by category.

    Therefore, I thought that I could edit the template file being used. And do the following:
    1. Check for a Custom Post Type (used by WP-Filebase) in an if statement.
    2. Then if that condition is true, get the taxonomy of the current Filebase category and store this in a variable.
    3. Use the do_shortcode function to call a WP Filebase category on the page.
    4. Use the variable to show the right category

    But since WP-Filebase isn't using Custom Post types like this, I don't know how to do this.

    Is this possible?

    Ps. I've added a screenshot of my situation.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WP-Filebase Download Manager
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic

Tags

No tags yet.