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

  • Home
  • SEARCH
  • 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 6587911
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T16:58:47+00:00 2026-05-25T16:58:47+00:00

Having a peculiar problem. I’m using a FormPanel to send data to a database

  • 0

Having a peculiar problem.

I’m using a FormPanel to send data to a database and uploading a file.

In Chrome this works fine, but in Firefox it sends the data to the database but does not upload the file. Firebug returns the following error:

Form contains a file input, but is missing method=POST and enctype=multipart/form-data on the form.  The file will not be sent.

I found this weird.
Checked the page source code and everything seems fine:

<form target="FormPanel_revanweb_1" action="phpFiles/newBookmark.php" enctype="ENCODING_MULTIPART" method="POST" style="position: absolute; left: 0px; top: 0px; right: 0px; bottom: 0px;" class="gwt-TabLayoutPanelContent">

This is how I built the form panel using UiBinder:

<g:FormPanel ui:field="formPanel" action="phpFiles/newBookmark.php" method="POST" encoding="ENCODING_MULTIPART">
    <g:VerticalPanel ui:field="tabNewWrapper" stylePrimaryName="tabNew-wrapper">
        <g:HTMLPanel ui:field="bookmarkNamePanel" styleName="container">
            <g:Label text="Bookmark Name:" />
            <g:TextBox name="txtBookmarkName" ui:field="txtBookmarkName" width="100%" />
        </g:HTMLPanel>
        <g:HTMLPanel ui:field="bookmarkURLPanel" styleName="container">
            <g:Label text="Bookmark URL:" styleName="label" />
            <g:TextBox name="txtBookmarkURL" ui:field="txtBookmarkURL" width="100%" />
        </g:HTMLPanel>
        <g:HTMLPanel ui:field="bookmarkDescriptionPanel" styleName="container">
            <g:Label text="Bookmark Description" styleName="label" />
            <g:TextArea name="txtBookmarkDescription" ui:field="txtBookmarkDescription" width="100%" height="60px" />
        </g:HTMLPanel>
        <g:HTMLPanel ui:field="bookmarkImgUploadPanel" styleName="container">
            <g:Label text="Image:" styleName="label" />                             
                <g:VerticalPanel ui:field="vpForm">
                    <g:FileUpload name="logo" ui:field="uploadFile" />
                </g:VerticalPanel>
        </g:HTMLPanel>
        <g:HTMLPanel ui:field="bookmarkcbActivePanel" styleName="container">
            <g:CheckBox  name="cbActive" ui:field="cbActive" text="Active?" styleName="label" />
        </g:HTMLPanel>
        <g:HTMLPanel ui:field="bookmarkTagsPanel" styleName="container">
            <g:Label text="Tags:" styleName="label" />
            <g:SuggestBox ui:field="sbBookmarkTags" animationEnabled="true" width="100%" />
        </g:HTMLPanel>
        <g:HTMLPanel ui:field="btnOKPanel" styleName="container">
            <g:SubmitButton ui:field="btnSubmit" text="OK" styleName="buttonOK" />
            <g:Label ui:field="lblWarning" visible="false" styleName="warning" />
            <g:Hidden ui:field="sessionID" name="sessionid" visible="false" />
        </g:HTMLPanel>
    </g:VerticalPanel>
</g:FormPanel>
  • 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-05-25T16:58:48+00:00Added an answer on May 25, 2026 at 4:58 pm

    You’re setting the encoding to ENCODING_MULTIPART, not multipart/form-data.

    NB: ENCODING_MULTIPART is a constant of type String, its not an enum; setEncoding on FormPanel takes a String as argument; so if you write ENCODING_MULTIPART in your ui.xml, you’ll set the string to "ENCODING_MULTIPART", not the value of the FormPanel.ENCODING_MULTIPART constant (which, btw, can only be referenced in a ui.xml using a <ui:import field="com.google.gwt.user.client.ui.FormPanel.ENCODING_MULTIPART" />, and then used as {ENCODING_MULTIPART})

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

Sidebar

Related Questions

Having a problem while passing messages using content scripts in Google chrome extension dev
I'm having quite a peculiar problem with PhoneGap and JQuery Mobile, using the latest
I am having a peculiar problem with the order in which FlowLayoutPanels are added
I am having a really peculiar case. I want to return some data -
I am having a peculiar problem with getting an integer from an ajax response.
I'm having the most peculiar problem, and I was hoping I someone could point
I am having a peculiar problem with the order in which TextBox controls are
This perhaps is a peculiar problem and I do need a second eye. I
Having a problem with git-based gems. gem file contents: ... gem 'spree', :git =>
Having a problem embedding a flash chatroom under a doctype equaling strict using the

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.