Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>First of all, you <strong>NEVER</strong> want to instantiate Seam components yourself (like in <code>new CiomemberHome()</code>), because if you do they are no longer Seam components (bijection will not work, etc.), instead of creating the instances yourself you ask Seam to handle them down with <code>Component.getInstance("memberHome")</code> or injecting it in FileUpload.</p> <p>Regarding your problem, I presume it is that the filename is empty. If this is the problem, then the reason is that richfaces is not actually creating the temporary files but has the content in memory. To store the uploaded data into files, you need to change your <code>web.xml</code>:</p> <pre><code>&lt;filter&gt; &lt;filter-name&gt;Seam Filter&lt;/filter-name&gt; &lt;filter-class&gt;org.jboss.seam.servlet.SeamFilter&lt;/filter-class&gt; &lt;init-param&gt; &lt;param-name&gt;createTempFiles&lt;/param-name&gt; &lt;param-value&gt;true&lt;/param-value&gt; &lt;/init-param&gt; &lt;init-param&gt; &lt;param-name&gt;maxRequestSize&lt;/param-name&gt; &lt;param-value&gt;10000000&lt;/param-value&gt; &lt;/init-param&gt; &lt;/filter&gt; </code></pre> <p>Note that <code>createTempFiles</code> is set to <code>true</code> (the default is false). When retrieving the data in listener, instead of <code>item.getData()</code> with a byte array use <code>File temp = item.getFile()</code> which returns the temporary file instance.</p> <p>See <a href="https://stackoverflow.com/a/7276813/1417546">https://stackoverflow.com/a/7276813/1417546</a></p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload