Automatic image renaming based on title
Hook into the filter ‘sanitize_file_name’. See my plugin Germanix URL for a working example. A plugin doing this is Rename Media.
Hook into the filter ‘sanitize_file_name’. See my plugin Germanix URL for a working example. A plugin doing this is Rename Media.
I found something very close that works here: http://oikos.org.uk/2011/09/tech-notes-using-resized-images-in-wordpress-galleries-and-lightboxes/
Observation: following the guidelines suggested in this article, I’m trying to improve the quality both of the Q and the A. It’s a learning process… In your original code, you were displaying different input fields according to the user role and other conditionals. add_action( ‘show_user_profile’, ‘user_fields_for_admin’, 10); add_action( ‘edit_user_profile’, ‘user_fields_for_admin’, 10); function user_fields_for_admin( $user ){ … Read more
Here’s how I managed to modify the page. For the submenu highlighting, however, I haven’t managed to figure it out, so I resort to jQuery. Here’s the code: /* – Set user filter links according to users pages * – Set Role Change dropdown menu * */ function custom_user_filter_links( $views ) { global $wp_roles; // … Read more
You can use the get_avatar filter to modify the output of the image tag and add your HTML attribute return apply_filters( ‘get_avatar’, $avatar, $id_or_email, $size, $default, $alt ); $avatar : Image tag for the user’s avatar.
Open comments.php file inside your theme’s folder <?php if ( comments_open() ) : ?> <?php $fields = array( ‘author’ => ‘<p class=”comment-form-author”>’ . ‘<label for=”author”>’ . __( ‘Name’, ‘responsive’ ) . ‘</label> ‘ . ( $req ? ‘<span class=”required”>*</span>’ : ” ) . ‘<input id=”author” name=”author” type=”text” value=”‘ . esc_attr( $commenter[‘comment_author’] ) . ‘” size=”30″ … Read more
To remove the profile picture row of the table (which includes the gravatar link): jQuery( “tr.user-profile-picture” ).remove(); To remove that entire “about yourself” table: jQuery( “tr.user-profile-picture” ).parents(“table:first”).remove(); Use this type of jQuery call, don’t try to get fancy with the loop. This is on WP 4.4; earlier versions may have different HTML class names for … Read more
Hi @hannit cohen: This slideshow from Beau Lebens should be able to show you how: Hooking into Comments And this blog post from Otto should be able to show you more: WordPress 3.0 Theme Tip: The Comment Form
Your theme must indicate that it supports post thumbnails: if ( function_exists(‘add_theme_support’) ) { add_theme_support(‘post-thumbnails’); // If not the standard size, state your size too set_post_thumbnail_size( 200, 200, false ); }
You are asking about the slug of a page. To change the URL part (also referred to as “slug”) containing the name of your Page, use the “Edit” (or “Change Permalinks” in older WordPress versions) button under the Page title on the Edit screen of the particular Page, accessible from Pages tab of WordPress Administration … Read more