Tobias Schutter
Forum Replies Created
-
Great. For two columns use the following:
function modify_user_table_row( $val, $column_name, $user_id ) { $field_name = 'fill in the title of your custom buddyPress user field'; // edit this value $field_name2 = 'fill in the title of your custom buddyPress user field'; // edit this value if ( 'buddypress_field' == $column_name ) { $val = xprofile_get_field_data( $field_name, $user_id ); } if ( 'buddypress_field2' == $column_name ) { $val = xprofile_get_field_data( $field_name2, $user_id ); } return $val; } add_filter( 'manage_users_custom_column','modify_user_table_row',10,3); function add_my_custom_buddypress_user_column( $column) { $column['buddypress_field'] = 'Column title goes here'; // you can edit this value $column['buddypress_field2'] = 'Column title goes here'; // you can edit this value return $column; } add_filter( 'manage_users_columns', 'add_my_custom_buddypress_user_column' );The problem is that the new imagesize (194×63) is not available. WordPress then looks for the closest available size which is the actual thumbnail.
To show the correct size you will have to add the image size, like so:
add_image_size('my-thumbnail-size', 194, 63);For the full code use this:
// edit here: fill in your thumbnail height and width $my_height = 63; $my_width = 194; // stop editing add_image_size( 'admin-columns-thumb', $my_width, $my_height, true ); add_filter('cpac_thumbnail_size', function() { return 'admin-columns-thumb'; });I will add this to make FAQ aswell.
This warning tells met that my plugin script also loads outside the editor page, which is not optimal.
I think it’s nice of the “Codestyling localization” to let me know my script loading can be optimised. So in the next release v0.2 I will address this.
In the meanwhile you can keep using the plugin if you’d like, it doesn’t hurt your website in anyway.
A bit of both, it will diminish my plugin popularity for sure 🙂
A couple of days later WPMU also wrote a post about my plugin which stated: “Impatience is a Virtue”, haha.
http://wpmu.org/wordpress-media-library-enhanced-media-picker/But honestly I think it’s really great they are giving the mediapicker a big overhaul. From what I have seen so for it’s going to be a welcome patch.
If my plugin would still add needed functionality after patch 3.5 I might even update it.
I will add your fix for this in next release, probably v1.4.7. I have removed my old response which was to typecast it to an array.
Thanks again for the report and fix!
Thank for reporting this and the very clear description of the issue. I will have a look and come back to you.
Your image ID is stored in a custom field. So you are doing it correctly by using the “media library icon” from the custom field box.
You can also set your own image size. Only not within the UI, you will have to add this to your themes functions.php in order to set your own size preference:
add_filter('cpac_thumbnail_size','my_custom_thumbsize'); function my_custom_thumbsize() { // width, height return array(30,30); }or
add_filter('cpac_thumbnail_size','my_custom_thumbsize'); function my_custom_thumbsize() { // or any other preset image size you have set, like thumbnail, medium, large etc. return 'medium'; }My plugin needed a fix before it could show/hide/reorder/relabel the WordPress SEO columns again. I fixed it in the latest release v1.4.6 and up.
http://wordpress.org/extend/plugins/codepress-admin-columns/
If you would like to remove the columns for all users without any coding you could use Codepress Admin Columns. You have the option to show/hide, re-order and re-label any column. Also works for the added columns of WordPress SEO by Yoast.
Your welcome 🙂 Good to know it is working properly again!
I have updated Codepress Admin Columns to version 1.4.6.
It should give you the option to show/hide/re-order/re-label any column that is placed by WordPress SEO by Yoast.
Explanation
WordPress SEO checks which page is being viewed before it loads it’s column headings ( through WPSEO_Metabox ). The columns headings weren’t being displayed, because my plugin loads a settings page instead of a overview page. So I added a fix specially for WordPress SEO which now does display the column headings.If you would like to remove the columns for all users without any coding you could use Codepress Admin Columns. You have the option to show/hide and reorder any column. Also works for the added columns of WordPress SEO by Yoast.
If you would like to remove the columns you could use Codepress Admin Columns. You have the option to show/hide and reorder any column. Also works for the added columns of WordPress SEO by Yoast.
Sorry for my late reply, I was monitoring the forum post by tag instead of the support tab.
But I found a fix to this issue. Update the plugin to the current version v1.4.6 and you should be able to drag and/or hide the WordPress SEO columns again.
Please let me know if it is working properly now.
Sorry that I missed your forum post. I was monitoring it on a different tag ‘codepress-admin-columns’ instead of ‘admin-columns’. I changed my RSS feed now so I’ll won’t miss them again.
But good news, I found a fix to this issue. Update the plugin to the current version v1.4.6 and you should be able to drag/hide the WordPress SEO columns once again.
Please let me know if everything is working as you would expect.
Tobias