You have this

window.opener.document.<%=formTarget%>.<%=elementT arget2%>.src="../images/<%=qStrDir%>/"+strValue;

And check if all the variables are correct.

or else this can be done simply by using plain JavaScript

Name the image with some id and then assign the src of that id to the image value

../images/<%=qStrDir%>/"+strValue