Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8560125
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T16:12:23+00:00 2026-06-11T16:12:23+00:00

I am trying to implement SWFUpload using the Play! framework and a Mac. When

  • 0

I am trying to implement SWFUpload using the Play! framework and a Mac.
When using a Mac I get a 302 error (Upload Error: 302). This seems, I think, to come from the redirect that happens by getting the upload page of the Play! framework (as it is translated from the routes file?).

It works fine on IE on Windows.

I have searched a lot, and read a lot, but haven’t found if there is a particular solution. Are there any suggestions on how to implement this, or any suggestions for another simple to implement file uploader (for big field, with progress)?

EDIT:

I have tried both Safari and Firefox on my Macbook and both return as status the 302 upload error. I tried again on Windows with IE and it works fine.

The html (stylesheet) code:

#{extends 'main.html' /}
#{set title: 'Upload Media File' /}

<script type="text/javascript" src="/public/swfupload/swfupload.js"></script>
<script type="text/javascript" src="/public/swfupload/swfupload.queue.js"></script>
<script type="text/javascript" src="/public/swfupload/fileprogress.js"></script>
<script type="text/javascript" src="/public/swfupload/handlers.js"></script>

<script type="text/javascript">
    var swfu;

    window.onload = function() {
    var settings = {
    flash_url : "/public/swfupload/swfupload.swf",
    flash9_url : "/public/swfupload/swfupload_fp9.swf",
    upload_url: "doUpload",
    file_post_name: "data",
    post_params: {"article.id" : "${article?.id}"},
    file_size_limit : "1000 MB",
    file_types : "*.*",
    file_types_description : "All Files",
    file_upload_limit : 1,
    file_queue_limit : 0,
    custom_settings : {
    progressTarget : "fsUploadProgress",
    cancelButtonId : "btnCancel"
    },
    debug: false,

    // Button settings
    button_image_url: "/public/swfupload/TestImageNoText_65x29.png",
    button_width: "65",
    button_height: "29",
    button_placeholder_id: "spanButtonPlaceHolder",
    button_text: '<span>Start</span>',
    button_text_style: ".theFont { font-size: 16; }",
    button_text_left_padding: 12,
    button_text_top_padding: 3,

    // The event handler functions are defined in handlers.js
    swfupload_preload_handler : preLoad,
    swfupload_load_failed_handler : loadFailed,
    file_queued_handler : fileQueued,
    file_queue_error_handler : fileQueueError,
    file_dialog_complete_handler : fileDialogComplete,
    upload_start_handler : uploadStart,
    upload_progress_handler : uploadProgress,
    upload_error_handler : uploadError,
    upload_success_handler : uploadSuccess,
    upload_complete_handler : uploadComplete,
    queue_complete_handler : queueComplete  // Queue plugin event
    };

    swfu = new SWFUpload(settings);
    };

</script>

<h2 class="title">#{get 'title' /}</h2>
<div style="clear: both;">&nbsp;</div>
#{form @index(), id:'uploadForm', enctype:'multipart/form-data'}
<div class="entity">
    <p>This page demonstrates a simple usage of SWFUpload.  It uses the Queue Plugin to simplify uploading or cancelling all queued files.</p>

    <div class="fieldset flash" id="fsUploadProgress">
        <span class="legend">Upload Queue</span>
    </div>
    <div id="divStatus">0 Files Uploaded</div>
    <div>
        <span id="spanButtonPlaceHolder"></span>
        <input id="btnCancel" type="button" value="Cancel All Uploads" onclick="swfu.cancelQueue();" disabled="disabled" style="margin-left: 2px; font-size: 8pt; height: 29px;" />
    </div>
</div>
#{/form}

The entry in the routes file (the Articles.upload is the screen, the doUpload is called by swfupload):

GET     /admin/articles/{id}/upload             Articles.upload
POST    /admin/articles/doUpload                Articles.doUpload

EDIT 2:
I also tried Uploadify, which returns the same error. Is there anybody who knows a workaround for the Play! framework or an uploader that does work with Play!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T16:12:25+00:00Added an answer on June 11, 2026 at 4:12 pm

    There is html 5 uploader at http://www.uploadify.com which can be downloaded for $5, and it works perfect for me so far.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have this weird kind of error. I am trying implement basic Euclidean algorithm
Trying to implement a search similar to here .This searches properties based on city,locality,property
Trying to implement simple error handling without adding buku try / except statements to
Trying to implement an autocomplete based on this It looks like it's very straight
I am trying to implement an SWFUpload on a form I have. However, it
Trying to implement search with Sunspot Gem wich is using Solr.Fulltext search works fine
I'm trying implement a way to recursively template using jsRender. The issue is, my
Trying to implement this gallery on my website. http://coffeescripter.com/code/ad-gallery/ It is noted in the
trying to implement a multiplayer. Using the sample from Game Center - Sending and
Trying to implement a shell, mainly piping. I've written this test case which I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.