Giter VIP home page Giter VIP logo

ajax-file-upload-struts2's People

ajax-file-upload-struts2's Issues

The taglibs URL is not working.

Hi,

 I am not able to use the "http://www.devedup.com/taglibs" url. This URL is no longer available. Please help us how we can make use this plugin?

Thanks in Advance,
Shashi


Original issue reported on code.google.com by [email protected] on 10 Nov 2011 at 8:44

in IE11, this upload control does not work, it crashes IE

What steps will reproduce the problem?
1. upload any image file using this control in a form as in example in IE11 
browser 
2. Though server side response has clear response, but request never end at 
client and crashes IE 11
3.

What is the expected output? What do you see instead?


What version of the product are you using? On what operating system?


Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 11 Aug 2014 at 6:25

ajax-file-upload-plugin-0.4.0.jar issue while integrating with struts2.1.6.

What steps will reproduce the problem?
1. the jsp page is shown below
<%@ taglib prefix="s" uri="/struts-tags"%>
<%@ taglib uri="http://www.devedup.com/taglibs" prefix="afile"%>
<head>
<script
src="http://yui.yahooapis.com/2.4.1/build/yahoo/yahoo-min.js"></script>  
<script
src="http://yui.yahooapis.com/2.4.1/build/event/event-min.js"></script>  
<script
src="http://yui.yahooapis.com/2.4.1/build/connection/connection-min.js"></script
>


<afile:head />

</head>
<style>
body {font-family:"Tahoma";}
.file_container {width:480px;font-size:11px;border: 1px solid
black;margin:0px;border-collapse:collapse;}
.filelist {font-size:11px;width:100%;margin:0px;border-collapse:collapse;}
#ajaxFileUploadForm .label {font-size:11px;}
#ajaxFileUploadForm input {font-size:11px;}
.filelist tr.odd {background-color:#eef;}
.filelist tr.even { background-color:#dde;}
.filelist tr td {padding:4px;}
</style>

<script>
    var callback =   
    {   
        cache:false,
        success: function(o) {document.getElementById('did').innerHTML =
o.responseText;}   
    }   
    function show_list() {
        var transaction = YAHOO.util.Connect.asyncRequest('GET',
'/jctaylor/FileUploadDetailsAction.action', callback, null); 
    }
</script>

<body>
    <table class="file_container">
        <tr><td>This demonstrates the use of Struts2 Ajax upload plugin and YUI
Ajax connect library.
        For more details see <a href="">here</a>.
        </td></tr>
        <tr>
            <td><afile:ajaxfileuploadform action="FileUploadDemoAction" dobefore=""
doafter="show_list" /></td>
        </tr>
        <tr>
            <td><div id='did'></div></td>
        </tr>
    </table> 
</body>



2. call this page assuming creating all the action classes and action
mapping provided by this link:
http://www.struts2.org/ajax-file-upload-in-struts2-using-ajax-file-upload-plugin
/

What is the expected output? What do you see instead?
1. I should see the page to browse the files
2. But I am seeing the 500 error page with the following error:
org.apache.jasper.JasperException: Template
/template/simple/progressbar-close.ftl not found. - Class:
freemarker.template.Configuration
File: Configuration.java
Method: getTemplate
Line: 489 - freemarker/template/Configuration.java:489:-1
    org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:515)
    org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:411)
    org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:322)
    org.apache.jasper.servlet.JspServlet.service(JspServlet.java:249)
    javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    org.apache.struts2.dispatcher.ServletDispatcherResult.doExecute(ServletDispatcherResult.java:154)
    org.apache.struts2.dispatcher.StrutsResultSupport.execute(StrutsResultSupport.java:186)
    com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:361)
    com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:265)
    com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:163)


What version of the product are you using? On what operating system?
I am using version ajax-file-upload-plugin-0.4.0.jar
with struts2.1.6 

Please provide any additional information below.
here is my action classes and mappings:
package ajaxupload.action;

import java.io.File;
import java.util.ArrayList;
import java.util.List;

import javax.servlet.http.HttpServletRequest;

import org.apache.struts2.interceptor.ServletRequestAware;

import com.devedup.ajaxfileupload.action.FileUpload;
import com.opensymphony.xwork2.Action;

public class FileUploadDemoAction extends FileUpload implements
ServletRequestAware{

    HttpServletRequest request;
    @SuppressWarnings("unchecked")
    public String execute() {
        File uploadedFile = this.getUpload();
        String contentType = this.getUploadContentType();
        String fileName = this.getUploadFileName();

        List<String> l =
(List<String>)request.getSession(true).getAttribute("uploaded_list");
        if(l== null) {
            l  = new ArrayList<String>();
            request.getSession(true).setAttribute("uploaded_list", l);
        }

        l.add("FileName: "+fileName+"\n"+"ContentType: "+contentType+"\n");
        return Action.SUCCESS;
    }

    public void setServletRequest(HttpServletRequest req) {
        request = req;
    }

}


Mapping file:

<action name="FileUploadDemoAction"
            class="ajaxupload.action.FileUploadDemoAction">
            <interceptor-ref name="fileUploadStack" />
            <result name="success" type="httpheader">
                <param name="status">200</param>
            </result>
        </action>
        <action name="FileUploadDetailsAction"
            class="ajaxupload.action.FileUploadDetailsAction">
            <result>/jctaylor/pages/insuranceApplication/uploadedFilelist.jsp</result>
        </action> 





Original issue reported on code.google.com by [email protected] on 25 Sep 2009 at 9:45

Instructions for using version 0.4

What needs to be changed to use 0.4 from 0.3?  I had 0.3 working and I
upgraded to 0.4 (along with upgrading struts to 2.1) and I get the
following error:

The absolute uri: http://www.davidjc.com/taglibs can not be resolved

Original issue reported on code.google.com by [email protected] on 30 Jul 2009 at 6:52

Progress bar can not display properly

What steps will reproduce the problem?
1. setup the example from 
http://www.struts2.org/ajax-file-upload-in-struts2-using-ajax-file-upload-
plugin/
2. Upload larg file


What is the expected output? What do you see instead?
  Progress bar should shown as per file upload progress.

What version of the product are you using? On what operating system?

ajax-file-upload-plugin-0.4.0 with struts 2.1.6.
Please provide any additional information below.


Original issue reported on code.google.com by [email protected] on 3 Aug 2009 at 5:12

svn not up to date

I am trying to download the source for version 0.4.0 but the trunk is still on 
0.3.0.
Where can I find the most recent sources ?
Thanks

Original issue reported on code.google.com by [email protected] on 15 Oct 2010 at 2:59

How to add text field to this Ajax file upload plugin?

What steps will reproduce the problem?
1. I don't know how to send in text through this Ajax file upload plugin

What is the expected output? What do you see instead?
I want to send in file title and description together with the uploaded 
file.  So I added the title and description string field in the form 

<@s.form id="ajaxFileUploadForm" onsubmit="return false" 
action="${parameters.action?html}" method="post" enctype="multipart/form-
data" >
<@s.file name="upload" id="upload" label="Select file"  accept="*/*" 
size="40" />
<@s.textfield name="title" id="title" label="Title" />
<@s.textarea name="description" id="description" label="Description" 
cols="50" rows="5" />
<@s.submit value="Upload" onclick="return hutufa.AjaxFileUpload.initialise
(${dobefore}, ${doafter});" />
</@s.form>


I also add the fields in FileUpload class.  

public abstract class FileUpload extends ActionSupport {
...

private File upload;
    private String contentType;
    private String filename;
    private String title;
    private String description;

...

public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }
...

}




But seems the added title and description fields were not picked up in the 
demo action.

    String title = getTitle();
    System.out.println(title);
    String description = getDescription();
    System.out.println(description);

What version of the product are you using? On what operating system?

I used the latest version in SVN.  

Please provide any additional information below.

It seems that the added two fields were not in the value stack, why?


Original issue reported on code.google.com by [email protected] on 15 Oct 2009 at 10:07

Error: java.lang.UnsupportedClassVersionError: Bad version number in .class file

What steps will reproduce the problem?
1. Downloading 0.4.0 version
2. Modifying everything for this version (Eg.: taglib to com.devedup...)
3. Compiling JSPs

-What version of the product are you using? On what operating system?
Java 5... is it compiled with Java 6 and that's the problem?

-Please provide any additional information below.
I've tried to download source code to recompile it myself with maven but source 
code here is 
previous 0.3 version.

Original issue reported on code.google.com by [email protected] on 21 Sep 2009 at 12:14

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.