How can I increase the font sizes used by the WordPress visual and HTML post editors?

Put this on the top of your functions.php file after the first <?php add_action( ‘admin_print_styles-post.php’, ‘my_admin_css’ ); add_action( ‘admin_print_styles-post-new.php’, ‘my_admin_css’ ); function my_admin_css() { ?> <style type=”text/css”> #editorcontainer textarea#content { font-size:130%!important } </style> <?php } The function will print out the additional CSS on the pages where you write posts only (so it’s not loading … Read more

How to disable Edit Post and Allow only Custom Field?

You can remove post type support for the editor on a conditional basis. The following should work: add_action( ‘add_meta_boxes’, ‘wpse45113_remove_editor’ ); function wpse45113_remove_editor() { // change the capability and post type to whatever is appropriate if ( ! current_user_can( ‘install_plugins’ ) ) remove_post_type_support( ‘post’, ‘editor’ ); } I’m using add_meta_boxes because it fires not too … Read more

How to change the post form from plugin?

If you want to change/add something to post form, you have to deal with meta boxes. I would recommend you to read through these articles: Reusable Custom Meta Boxes Part 1: Intro and Basic Fields Reusable Custom Meta Boxes Part 2: Advanced Fields Reusable Custom Meta Boxes Part 3: Extra Fields Reusable Custom Meta Boxes … Read more

Is there a query string for edit.php to show all posts that have no custom taxonomy terms?

Use a tax_query with a NOT IN operator. $args = array( ‘post_type’ => ‘post’, ‘tax_query’ => array( array( ‘taxonomy’ => ‘sms_premium_posts’, ‘field’ => ‘slug’, ‘terms’ => ‘Premium’, ‘operator’ => ‘NOT IN’ ) ) ); $query = new WP_Query( $args ); Now, to make that work on the post edit page via a $_GET string something … Read more

Suddenly new posts have the default permalink instead of the post name

Nothing just happens for “no apparent reason”. Some new condition has caused this. Most likely a new plugin or update of an existing plugin. It is possible for a plugin or theme doing something crazy like flushing rewrite rules on every load could wipeout the existing rules. See this ticket for more info: http://core.trac.wordpress.org/ticket/18450#comment:34 if … Read more

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