Pods pagination erases my sub menu

You can disable pagination per find() query in Pods by setting ‘pagination’ => false, I also suggest disabling search with ‘search’ => false. You can do this globally by setting these constants, which means you’ll have to explicitly enable search or pagination on the queries you want them enabled on by setting ‘pagination’ => true … Read more

Pods: Authors to Custom Field

Solved! I’ve created this script: <?php global $wpdb; $postwp = $wpdb->get_results ( “SELECT ID,post_author,post_title FROM wp_posts WHERE post_status=”publish” and post_type=”post”” ); $users = $wpdb->get_results ( “SELECT post_id,meta_value FROM wp_postmeta where meta_key = ‘id_utente_user'” ); foreach($postwp as $key1=>$value1) { foreach($users as $key2=>$value2) { if($value1->post_author==$value2->meta_value) { add_post_meta( $value1->ID, ‘autore’, $value2->post_id ); } } } ?> I hope … Read more

Passing taxonomy id of taxonomy clicked on one page to another page

Your list of products is a list of taxonomy terms. You can get this list with those functions: get_terms($args) — Retrieve the terms in a given taxonomy or list of taxonomies. get_the_terms($post, $taxonomy) — Retrieve the terms of the taxonomy that are attached to the post. Clicking on a Product — is opening a custom … Read more

File Upload Management

You can start yout work with upload_dir filtering. However, I wouldn’t recommend it (change this functionality). You will need to track few types of uploads and then track whoever is the parent of the upload. It’s more complicated, then joyful task.

How to change pods ACT upload dir

The short answer here is you can’t check whether the upload is coming from a Pods Advanced Content Type, especially since the media that gets uploaded has no post_id associated to it (it’s not a post at that point). The longer answer is that you can still customize this if your file upload field is … Read more

How to check if WordPress object type is already extended by pods

It turns out that Pods handles this exactly as you would expect. It doesn’t differentiate between completely new post types and extending post types in the Pods API. To check if the WP_User class is being extended by pods, the method is identical: // pods() returns false if there’s no extended class for `user` if … Read more

profile_update works on second update only

Not long after posing this question I figured it out. But since I had spent a few hours looking for the awswer I thought maybe it would be worth posting. I hope this does not break any rules. I changed the default priority from 10 to 11. as per: add_action( ‘profile_update’, ‘initiate_participant_profile_update’, 10, 2 ); … Read more