the_content – native code
-
Hey there, I’m adding the TimThumb plugin to my theme, but i got into an issue.
I’m adding this just before the_content tag:
<?php if ( get_post_meta($post->ID, 'thumb', true) ) { ?> <img class="postthumb" src="<?php bloginfo('template_directory'); ?>/scripts/timthumb.php?src=<?php echo get_post_meta($post->ID, "thumb", $single = true); ?>&h=150&w=150&zc=1" alt="<?php the_title(); ?>" width="100" height="57" /> <?php } ?>It works great, but since that html tag is outside the <p> of the the_content, the text of the post cant get wraped around the image – if I add an image the normal way, it gets wrapped, the text is being justified.
I’m thinking about adding that initial code for the TimThumb image inside the <p> that is inside the the_content, but obviously I cant do it. So, I guess that the_theme tag is like an include, but where’s located the code to be included?
Or even better, I’d like to replace the the_content tag by the code it represents.I’d really like some help 🙂
Thanks
The topic ‘the_content – native code’ is closed to new replies.