Custom fields in wordpress
Custom fields in wordpress are important if you want to use custom functions in your theme or if you want to have a clean design. The implementation of custom fields is relatively easy.
Open your style.css file and paste the following code:
.leadpic {
float:left;
width:200px;
height:100px;
border:1px solid #bebebe;
padding:5px;
margin:10px 10px 10px 10px;
}
The code above can be customized as you want.
Now open the index.php file and search the following code:
<?php if (have_posts()) : while (have_posts()) : the_post
Under this code paste the following code:
<?php
$values = get_post_custom_values("Image");
if (isset($values[0])) {
?>
<div>
<a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><img src="<?php $values = get_post_custom_values("Image"); echo $values[0]; ?>" alt="" width="200px" height="100px" /></a>
</div>
<?php } ?>
To use this custom field you must add a new custom field from wordpress post options.
On the key field put image and on the value field put your image url.
The entire code from this article can be easily customized. For any questions feel free to post a comment.

Hi. I am Marian, the owner of WPCONCEPT. I am a freelancer web designer focused on web development and i am a big fan of wordpress.
I am from Transylvania, Romania and please excuse my grammar mistakes. I do my best to improve my english skills.
by Christian Louboutin on 11 June 2010 - Permalink
my favorite web page. thank you