How to paginate attachments in a secondary query as gallery?

I’m assuming you want something like this: |———————| | content | | (static) | |———————| | gallery | | (paged) | |———————| | << pagelinks >> | |———————| In this setup your the post content stays the same, appears to be static, while the gallery is paged. This means you have the main query, showing … Read more

Specify image dimensions

In your theme’s functions.php file you can add add_image_size( ‘thumb’, 600, 350, true ); add_image_size( ‘thumbnil’, 600, 350, true ); add_image_size( ‘medium’, 600, 350, true ); add_image_size( ‘large’, 600, 350, true ); add_image_size( ‘post-thumbnail’, 600, 350, true ); add_image_size( ‘{custom-image-type}’, 600, 350, true ); For more information have a look at http://codex.wordpress.org/Function_Reference/add_image_size

Responsive Images

To add to the answer from @cristian.raiber, there is no function in WordPress or php to detect screen sizes, and there will in all probabilty never be such functionality. Php runs server side, which runs before clients side which is browser side. As for php, and for that matter WordPress, I cannot see any future … Read more

Remove title attribute from images

I would strongly discourage this. A better, more sustainable practice would be to educate your clients on the value of the title attribute and teach them how to use it properly. Simply removing it is putting a bandage on the symptom, not combating the disease. However, if you do want to remove the attribute anyway, … Read more

Default Image Link Removal

This is not able to be changed through a filter. In WordPress 2.9.2 and lower, the setting can be changed in /wp-admin/options.php. The image_default_link_type field is set to “file” by default. If you set it to “none”, then scroll to the bottom and save, it will disable media links. This option has been removed from … Read more

How to use get_template_directory_uri() to load an image that is in a sub-folder of my theme?

You should echo it and also you are closing your php tag improperly. View source the o/p generated to get some idea img<src=<?php echo get_template_directory_uri().”/assets/img/flexslider/flex-1.jpg”?> alt=”alternative_name”> or you can use bloginfo which is easier to remember and use (You need not echo) <img src=”<?php bloginfo(‘template_url’); ?>/assets/img/flexslider/flex-1.jpg”/>