I use the <p:media> to display static PDF content.
<p:media value="/resource/test.pdf"
width="100%" height="300px" player="pdf">
</p:media>
How can I change it to display dynamic content?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Like as in
<p:graphicImage>, thevalueattribute can point to a bean property returningStreamedContent. This only requires a special getter method for the reasons which is explained in detail in the following answer on using<p:graphicImage>with a dynamic resource from a database: Display dynamic image from database with p:graphicImage and StreamedContent.In your particular example, it would look like this:
With