El lun, 07-05-2007 a las 03:22 -0700, omidh escribió: > Referencing : > http://jsffaq.com/Wiki.jsp?ptitle=How+to+download+PDF+file+with+JSF% > 3F&page=HowToDownloadPDFFileWithJSF > I would like to know if there is the possibility to resolve the contentType > "automatically"?? >
I used to save it in database with the content, size, title, name, etc... Look here. This turns the extension to a mime type: http://java.sun.com/products/javabeans/jaf/downloads/index.html > regards Omid. > > > Josué Alcalde González-2 wrote: > > > > El dom, 06-05-2007 a las 23:30 -0700, omidh escribió: > >> Hi, > >> > >> can anyone tell me please, how to make a link for a file download?! > >> The File is saved in a database (Mysql). > >> > >> so when I use <h:outputLink value="bean.file"> > >> I get the message that the URL must be absolut. > >> > >> thansk in advance, > >> Omid > > > > There are diferent options: > > > > -Download it from an action method using command link or command button: > > > > http://jsffaq.com/Wiki.jsp?ptitle=How+to+download+PDF+file+with+JSF% > > 3F&page=HowToDownloadPDFFileWithJSF > > > > - Use a phaseListener to handle downloads of files: > > http://jroller.com/page/cagataycivici?entry=phaselistener_renders_an_image_no > > > > > > > > -- > > _______________________________________________ > > Josué Alcalde González > > [EMAIL PROTECTED] > > Dpto. Desarrollo > > > > CSA - Centro Regional de Servicios Avanzados > > C/ López Bravo, 1 > > Pol. Ind. Villalonquéjar (Burgos) > > > > Tel. (+34) 947 256 250 > > Fax. (+34) 947 256 583 > > > > Web: http://www.csa.es > > > > > > > > > -- _______________________________________________ Josué Alcalde González [EMAIL PROTECTED] Dpto. Desarrollo CSA - Centro Regional de Servicios Avanzados C/ López Bravo, 1 Pol. Ind. Villalonquéjar (Burgos) Tel. (+34) 947 256 250 Fax. (+34) 947 256 583 Web: http://www.csa.es

