title: CQ5 How do I render an image by InputStream from jcr:data?
body: <p>I saved my image using the <em>foundation/components/image</em> component, but I can not get the image again.</p>
  
  <p>My JSP Code:</p>
  
  <pre><code>String src = "";
  
  if(image.hasProperty("fileReference")){
      src = image.getProperty("fileReference").getString();
  
  }else if(image.hasNode("file")){
      Node jcrContent = image.getNode("file").getNode("jcr:content");
  
      InputStream iContent = jcrContent.getProperty("jcr:data").getBinary().getStream();
  
      out.print(iContent);
  
      jcrContent.getProperty("jcr:data").getBinary().dispose();
  }
  
   &lt;img src="&lt;%= src %&gt;"&gt;
  </code></pre>
  
  <p>And my <strong>image</strong> is a Node.</p>