Changing the CSS in javascript will help you to get solution:
add css in your function:
function show_image(src) {
var img = document.createElement("img");
img.src = src;
document.body.appendChild(img);
$(document).find(img).css(here add your styles);
}
example : $(your element).css(“color”, “red”);