title: how to show an image in p:dialog from a datable
body: <p>I'm using primefaces to show a datable : </p>
  
  <p>I have a column in my datable , it's an image , what i want is when i clic in the image , a p:dialog show the image with a big dimension . </p>
  
  <p>I did it but the p:dialog show the wrong image, it shows the image of the last row in the datable .</p>
  
  <pre><code>&lt;p:column headerText="imagePath"&gt;
    &lt;h:graphicImage library="images" name="#{book.imagePath}.png" 
                    width="75px" onclick="PF('dlg').show();"/&gt;
    &lt;p:dialog widgetVar="dlg" resizable="f" height="600px"width="500px"onShow="js"&gt;
      &lt;h:graphicImage  library="images" name="#{book.imagePath}.png"width="400px"/&gt;
    &lt;/p:dialog&gt;
  &lt;/p:column&gt;
  </code></pre>
  
  <p>Thank you</p>
  
  <p><strong>I have solved the problem with the commandlink component</strong> </p>
  
  <pre><code>&lt;p:column headerText="imagePath"&gt;
    &lt;p:commandLink update=":zaki:foo:imgDlg1" oncomplete="dlg1.show()"
                   action="#{jsfClient.showImg(book)}"&gt;
      &lt;h:graphicImage value="/resources/images/#{book.imagePath}.png" width="75px"/&gt;
    &lt;/p:commandLink&gt;
  &lt;/p:column&gt;
  </code></pre>
  
  <p>I have put in image into a commandlink and it works perfect , note that i have put the p:dialog out from the datable.</p>