![]() |
How to have two image sizes in WP?
Hi
Okay so lets say I want 500px Width images in index of wordpress, but when you click on the post the image size changes to say 800px - is this possible? Thanks B |
yes it will posible :)
|
Quote:
http://codex.wordpress.org/Function_...add_image_size |
First of all enable "Custom Fields" under "Screen Options".
under "Name" put "thumb" and under "Value" insert link to your 500px picture. Next you need to edit your index.php file and add this: Code:
<?php if( get_post_meta($post->ID, "thumb", true) ): ?> |
Quote:
all that extra work is pointless. |
add to functions.php:
Code:
add_theme_support( 'post-thumbnails' ); Code:
<?php if ( has_post_thumbnail() ) { the_post_thumbnail( 'homepage-thumb' ); } ?> |
Then install this if you have been using a different size:
http://wordpress.org/extend/plugins/...te-thumbnails/ Personally I would use excerpt to produce the text and maybe put something like this in functions.php: Code:
function new_excerpt_length($length) { |
Quote:
|
All times are GMT -7. The time now is 10:52 PM. |
Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123