• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 117
  • Last Modified:

Firefox got stuck on file uploading page

I currently have a very weird thing happened on the file uploading page between safari and firefox.

the web page let a user upload multiple images to the server, after the user choose the files he wants to upload, and click on the upload button, all the files will be uploaded to the server by using Jquery. both safari and firefox have no problem on this process so far. I can see the uploading process is 100% done.

after clicking on upload button
The problem is------ the Safari browser allow the user to click on the button NEXT to move forward to the next page, but the firefox (version 47.01) does not.

The uploading function is from this link:


the example 11 from the link above is what I am using.

"With release v4.0.0, the plugin now supports AJAX based uploads using HTML 5 FormData and XHR2 protocol, which is supported in most modern browsers." is copied from this page:


doesn't Firefox 47.01 support AJAX?

Below are my configuration :

The action snippet  inside my struts.xml is:
         <action name="doUpload" class="xxx.eblast.report.FileUploadAction"  method="execute"> 
          <result type="json" />

Open in new window

the form to upload file is:
       <div class="container kv-main">

               <form enctype="multipart/form-data">
                 <div class="form-group">
                    <input id="file-10" name=upload type="file" multiple class="file-loading">


Open in new window

    uploadUrl: "doUpload", 
    allowedFileTypes: ["image", "video"],
    allowedFileExtensions: ["png", "jpeg", "jpg", "gif"],
    uploadAsync: false,
    maxFileCount: 10,
    uploadClass: "btn btn-success",
    uploadLabel: "Upload",
    uploadIcon: "<i class=\"glyphicon glyphicon-upload\"></i> "

Open in new window

The snippet for the next button is:
<div class="container clearfix"  > 
	        <div class="row-fluid" >   
		    <s:url action="composeEmail" var="urlTag" ></s:url>
		    <button type="button" class="btn btn-default pull-right"><s:a href="%{urlTag}" > NEXT </s:a></button>

 	    </div><!-- row fluid -->
    </div> <!-- container -->

Open in new window

the action is:

<action name="composeEmail">

Open in new window

Arthur Wang
Arthur Wang
1 Solution
Dave BaldwinFixer of ProblemsCommented:
doesn't Firefox 47.01 support AJAX?
Of course it does or the upload wouldn't happen.  Your 'Next' button is not part of the AJAX function, it's part of your code that you added.
Kim WalkerWeb Programmer/TechnicianCommented:
It is invalid HTML to embed an <a> link inside a <button>. Both are clickable elements and therefore create a conundrum for the browser to determine which element fires the click event. The converse is also invalid, you cannot embed a <button> inside and <a> link. If you validate your HTML, you will see an error for this code.
Arthur WangAuthor Commented:
After more testing on the "NEXT" button, I finally decide to use form button to replace the button link such that it can be working on both Safari and Firefox browser.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

The 14th Annual Expert Award Winners

The results are in! Meet the top members of our 2017 Expert Awards. Congratulations to all who qualified!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now