Sure.
I'll only comment changed lines.
$imagestring = "<br /><br /><IMG SRC=\"$config[fileurl]/$File\" width=\"{$config['max_width']}\" Border=\"0\" alt=\"{$ubbt_lang['FILE_ATTACH']}\">";
I just add the image code in a variable instead of adding it to the body.
$imagestring = "<br /><br /><IMG SRC=\"$config[fileurl]/$File\" Border=\"0\" alt=\"{$ubbt_lang['FILE_ATTACH']}\">";
Same thing here. This line is for when the image doesn't need to be resized.
if ( !strpos($Body, "[imageplacement]") ) {
From here on, all lines are new. This line checks if the string "[imageplacement]" is somewhere in the body.
$TempBod .= $imagestring;
No image placement tag found, so we just add the html code for the image, which we've already placed in the $imagestring variable, at the end of the message body.
$TempBod = str_replace("[imageplacement]", $imagestring, $Body);
The [imageplacement]-tag was found, so we replace that with the html code for the image, which we have in the variable $imagestring.
BTW, does it work?