fileUploadListener not working again

UI Components for JSF
Post Reply
linwh0520
Posts: 8
Joined: 11 Nov 2010, 16:22

07 Jan 2011, 22:34

Primefaces 1.1, JSF 1.2, glassfish v2

Found tens of post about this issus, but it is still not soloved yet....

fileUploadListener method is not fired,

Code: Select all

<context-param>
<param-name>javax.faces.STATE_SAVING_METHOD</param-name>
<param-value>server</param-value>
</context-param>
<filter>
        <filter-name>PrimeFaces FileUpload Filter</filter-name>
        <filter-class>org.primefaces.webapp.filter.FileUploadFilter</filter-class>
        <init-param>
            <param-name>thresholdSize</param-name>
            <param-value>51200</param-value>
        </init-param>
        <init-param>
            <param-name>uploadDirectory</param-name>
            <param-value>/tmp/fileUpload</param-value>
        </init-param>
 </filter>

<filter-mapping>
        <filter-name>PrimeFaces FileUpload Filter</filter-name>
        <servlet-name>Faces Servlet</servlet-name>
    </filter-mapping>

Code: Select all

 <p:fileUpload fileUploadListener="#{managedBean.doUpload}"  />

Code: Select all

 public void doUpload(FileUploadEvent event)
    {
        System.out.println("#################################");
    }


Any help would be appreciated!

ethode
Posts: 1
Joined: 23 Mar 2013, 04:27

26 Mar 2013, 17:49

linwh0520 wrote:Primefaces 1.1, JSF 1.2, glassfish v2

Found tens of post about this issus, but it is still not soloved yet....

fileUploadListener method is not fired,

Code: Select all

<context-param>
<param-name>javax.faces.STATE_SAVING_METHOD</param-name>
<param-value>server</param-value>
</context-param>
<filter>
        <filter-name>PrimeFaces FileUpload Filter</filter-name>
        <filter-class>org.primefaces.webapp.filter.FileUploadFilter</filter-class>
        <init-param>
            <param-name>thresholdSize</param-name>
            <param-value>51200</param-value>
        </init-param>
        <init-param>
            <param-name>uploadDirectory</param-name>
            <param-value>/tmp/fileUpload</param-value>
        </init-param>
 </filter>

<filter-mapping>
        <filter-name>PrimeFaces FileUpload Filter</filter-name>
        <servlet-name>Faces Servlet</servlet-name>
    </filter-mapping>

Code: Select all

 <p:fileUpload fileUploadListener="#{managedBean.doUpload}"  />

Code: Select all

 public void doUpload(FileUploadEvent event)
    {
        System.out.println("#################################");
    }


Any help would be appreciated!
Did you ever find a solution for this problem?

kukeltje
Expert Member
Posts: 9605
Joined: 17 Jun 2010, 13:34
Location: Netherlands

26 Mar 2013, 20:00

Primefaces 1.1 is not supported anymore (and read the forum posting rules)

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 56 guests