unity3software
Forum Replies Created
-
Forum: Plugins
In reply to: [Adminimize] New Version released, Tests are welcome.Hello Frank,
I’ve tested the “select all” functionality and it works great! Thanks for your on going contribution to this wonderful plugin
All the best to you Scott from another “under the weather” developer. (okay, where’s my medicine)
I’ve been away for a few weeks but I am anxiously anticipating the release of repeated fields. I’m tired of work arounds for such a great framework. We’re counting on you PODS!
Thanks for the update Scott. PODs is becoming more deeply integrated into my WordPress builds. It will be a breath of fresh air to add repeated fields into my arsenal.
Anticipating 3.0
Forum: Plugins
In reply to: [Pods - Custom Content Types and Fields] Presave Function – Edit Post TitleJosh, pods_api_pre_save_pod_item does not work because $pieces[‘fields’] only refers to custom meta fields. The default post fields such as ‘post_title’ are only found in: $pieces[‘object_fields’]. However, these only appear to be field descriptors because there is no ‘value’ property to any of these fields.
Gattermeier, here is my current hack for this POD bug. Hook into the ‘wp_insert_post_data’ filter, which runs for every post add/edit/update. To access the metadata, use: $postarr[ ‘pod_meta_%my_meta_name%’]. By the way, this filter runs BEFORE pods_api_pre_save_pod_item.
function wp_pre_save( $data , $postarr ) { //$data['post_title'] = $postarr['pods_meta_width'].'x'.$postarr['pods_meta_length']; if ($data['post_type'] == 'metal_building') { $width = $postarr['pods_meta_width']; $length = $postarr['pods_meta_length']; if (!empty($width) && !empty($length)) { $data['post_title'] = $data['post_name'] = $width.'x'.$length; } } return $data; } add_filter( 'wp_insert_post_data', array($this,'wp_pre_save'), '99', 2 );
Forum: Plugins
In reply to: [Pods - Custom Content Types and Fields] Presave Function – Edit Post TitleThe POD is created from a custom post type
Forum: Plugins
In reply to: [Pods - Custom Content Types and Fields] Presave Function – Edit Post TitleMy custom fields that I have defined via PODS. But to the question, how best can I access the post_title field during ‘pre_save_pod_item’ action?
Thanks Scott, my fingers are crossed. ??