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 9167817
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T15:29:00+00:00 2026-06-17T15:29:00+00:00

Within my form, called frmClock, I have a div that is ultimately used as

  • 0

Within my form, called frmClock, I have a div that is ultimately used as the basis for a jQuery UI modal dialog:

    <div id="dialog-form-clockout" title="Associate Mileage Reimbursement" data-ok="<%=clkContinueClockOut%>" data-cancel="<%=clkCancel%>" data-errornum="Invalid number format. Valid number format is 999.9" data-errorzero="Please enter a value greater than zero. Otherwise, select No." data-errormaxchars="Please enter a numeric value less than 5 characters long." data-errornoradio="Please select Yes or No.">
        <fieldset>        
            <div id="personalVehicle">
                <label for="<%=TAConstants.FN_ASM_RESPONSE%>">Did you use your personal vehicle for business travel during this shift?</label>
                <br>
                <input type="radio" name="<%=TAConstants.FN_ASM_RESPONSE%>" id="personalvehicle" class="text ui-widget-content ui-corner-all" value="Y"/>Yes
                &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                <input type="radio" name="<%=TAConstants.FN_ASM_RESPONSE%>" id="personalvehicle" class="text ui-widget-content ui-corner-all" value="N"/>No
                <br>
            </div>
            <div id="questionsY" class="hidden">
                <div class="modalDialogQuestions">
                    <label for="<%=TAConstants.FN_BANK_ROUND_TRIPS%>" class="modalDialogQuestionsLbl">Enter number of round-trips to the bank.</label>  
                    <select name="<%=TAConstants.FN_BANK_ROUND_TRIPS%>" class="modalDialogAnswers" id="roundtrips">
                        <option selected value="0">0</option>
                        <option value="1">1</option>
                        <option value="2">2</option>
                        <option value="3">3</option>
                    </select>
                </div>
                <div class="modalDialogQuestions">
                    <label for="<%=TAConstants.FN_OTHER_MILES%>" class="modalDialogQuestionsLbl">Enter number of miles for business related travel other than the bank.</label>     
                    <input class="positive modalDialogAnswers" type="number" name="<%=TAConstants.FN_OTHER_MILES%>" id="mileage" value="0.0" maxlength=5/>
                </div>
            </div>
        </fieldset>
        <div class="ui-state-error hidden" style="height:auto;"><span class="ui-icon ui-icon-alert" style="display:inline; margin-right:.25em; float:left;"/></span><p class="validateTips" style="display:inline; border:0px;"></p></div>
    </div>
</form>

So ultimately once we fill out this jQuery modal dialog form, I use the same javascript we used to use prior to this enhancement for form submission (plus alerts to tell me this data is in the document element).

    alert(document.getElementById('personalvehicle').value);
    alert(document.getElementById('roundtrips').value);
    alert(document.getElementById('mileage').value);

    submitForm();

…

/**
 *  This function disallows the form to be submitted twice.
 */
function submitForm () {
  if (!hasBeenSubmitted) {
    hasBeenSubmitted = true;
    document.frmClock.submit();
  }

The alerts display the same text the user inputs, but doesn’t seem to be sent with the rest of the form data that we’ve received in the past without the jQuery modal dialog form. I’ve been determining this from our processor .java file, with the following code that doesn’t seem to set the vars, as it doesn’t pass null checks:

if (req.getParameter(FN_ASM_RESPONSE)!=null){
    Character asmResponse = (req.getParameter(FN_ASM_RESPONSE)).charAt(0);
}
if (req.getParameter(FN_BANK_ROUND_TRIPS)!=null){
    Integer bankRoundTrips = Integer.parseInt(req.getParameter(FN_BANK_ROUND_TRIPS));
}
if (req.getParameter(FN_OTHER_MILES)!=null){
    Float otherMiles = Float.parseFloat(req.getParameter(FN_OTHER_MILES));
}

The most I’ve heard is to make sure my inputs have the name attribute. These name attributes seem to be set though, view source shows them as personalvehicle, roundtrips, and mileage, which were set from the following constants .java file:

public static final String FN_ASM_RESPONSE = "personalvehicle";
public static final String FN_BANK_ROUND_TRIPS = "roundtrips";
public static final String FN_OTHER_MILES = "mileage";

Does anyone have any ideas as to what I ought to look into or try? Breakpoints on the getParameter() methods to check if null show it hits these points, but doesn’t hit what is contained because the parameters are null.

  • 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-17T15:29:01+00:00Added an answer on June 17, 2026 at 3:29 pm

    The problem is that jQuery UI moves the dialog containing your input field out of the form.

    You can change your dialog loading function to add a function that runs when the dialog is created and move it back to your form.

    $('#myDialog').dialog({  create: function () { $(this).parent().appendTo('form') } });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

A ComboBox within a Form (modal dialog) does not open when clicked, however an
I have a form called frmLogin. I have code within the Login_1Authenticate event handler
I have a top-level page called ReceiveItem . Within that page, I have a
I have one main windows form and within that form I have custom controls
I have a winform application that goes with name myForm . Within this form
I have a page called review.asp with a form that produces a list of
Within a web form I have the following jQuery setup to call a method
I have a view called volunteer_edit. Within volunteer_edit, I use jQuery to loop through
I have a form within an ASP.NET MVC application and I'm trying to submit
I have a complex input form within a PHP based web application. To structure

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.