ooops. sorry. I did not read the title. well, so you want such a html code to appear before title, dont you?
Then do following.
function the_title($before = '[html code here]', $after = '', $echo = true) {
$title = get_the_title();
if ( strlen($title) == 0 )
return;
$imgname = get_post_meta($post->ID, $key, true);
$title = '<div><div style="float:left; margin-right: 5px"><img src="'.$imgname.'" /></div><div style="float:left; margin-right: 5px">'.$title.'</div></div>';
$title = $before . $title . $after;
if ( $echo )
echo $title;
else
return $title;
}