A theme caused you site to crash? Probably a conflict with a plugin etc
In your index.php or home.php file, the place where the image goes put <a href="your-link or permalink"><img src="/path/to/<?php echo get_post_meta($post->ID,custom field name, true); ?">"></a>
then in the post area add a custom field, the name is custom field name and the value is the image name. Note i dont thinks this is the easiest way just trying too help you with your question
