Anpress point to WP Categories?

8.43K viewsGeneral
0

I am developing a site and it revolves around Anspress. I have a BNWF plugin that utilizes WP Categories to fire off notifications of a new post.
The issue I’ve ran across is that with Anspress categories add on, it creates an entire new category type. I added the category add on in order to have the category drop down appear on the submit a question form.
I was wondering if it is possible to point the Anspress Categories to the default WP Categories (that all the notifications are tied to) so that when a new question is submitted the notifications are fired off for that category. I have something like 75 different categories there.

Answered question
0

For this you need to edit whole category addon. Simply copy category addon directory and rename it. Then open PHP file and find for question_category taxonomy in all file and replace with category.
Comment line 43 in category.php. and add this hook:

add_filter( 'ap_question_cpt_args', function( $args ){
    $args['taxonomies'] = array( 'category' );
    return $args;
});


And now disable default category addon and enable yours.

Posted new comment

Following the steps mentioned here. Renamed the “categories” folder and added it under the Anspress Addons folder. But the new folder (addon) is not showing up as an available Addon in WordPress Admin dashboard – AnsPress Add-ons page. Am I missing something here? Thanks for your help in advance.

You are viewing 1 out of 4 answers, click here to view all answers.