you'd need to first format the results page after you do the insert. How I would do it is print he ending page as an html page with the frames as if it were any other page. That'd be the most direct method.
in other words, your result page wouldn't be blank anymore, it would be an html page with the frames.