Modify users.php query with multiple taxonomies

Because I’m also storing the user IDs against each company, office and team post object as user taxonomy I can reverse the query and only include the user IDs assigned to that specific post object. A similar thing to what has been done here – http://mywebsiteadvisor.com/learning/tutorials/building-simple-groups-plugin-for-wordpress-tutorial/step-5/ Only I’ve modified it to be a bit more … Read more

How to group posts and get a mixed posts and groups view?

A custom taxonomy makes perfect sense – here’s hoping I haven’t missed something: $songs = get_posts( array( ‘post_type’ => ‘song’, ) ); $index = array(); // Build an album_id => songs index foreach ( $songs as $song ) { if ( $albums = get_the_terms( $song->ID, ‘album’ ) ) $index[ $albums[0]->term_id ][] = $song; else $index[ … Read more

WordPress query with items from more than one selfdefined taxonomy as `term` argument

I managed to do it. I used the following query parameter: ‘tax_query’ => array( array(‘taxonomy’ => ‘wpccategories’, ‘field’ => ‘slug’, ‘terms’ => $termz ) ) With $termz being: $termz = wp_get_object_terms($id, ‘wpccategories’, array(“fields” => “slugs”)); The problem I struggled with was that I needed to use singular ‘field’with singular ‘slug’ in the tax_query (I knew … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)