Resource at upload

UI Components for JSF
Post Reply
rider
Posts: 497
Joined: 05 Mar 2010, 13:17

27 Apr 2010, 10:12

Hello,
I want to create the upload to my page:
But I can´t find the uploaded file at my Hard disk.
What should I change that I find the uploaded file?
It uploaded the file, but I can´t find it!


Here my web.xml

Code: Select all

	<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>/resources/images</param-value>
		</init-param>
	</filter>

Code: Select all

    public void handleFileUpload(FileUploadEvent event) {  
            logger.info("Uploaded: {}", event.getFile().getFileName());  
       
             FacesMessage msg = new FacesMessage("Succesful", event.getFile().getFileName() + " is uploaded.");  
             FacesContext.getCurrentInstance().addMessage(null, msg);  
    }  
Primefaces 12.0, WildFly 21

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: Google [Bot] and 35 guests