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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T20:07:39+00:00 2026-06-13T20:07:39+00:00

I have the following form with some data that I need to send. <form

  • 0

I have the following form with some data that I need to send.

<form action="http://localhost/sp/index.php/daily_operation/turn_close" method="post" accept-charset="utf-8" id="form" name="form" class="form_cash"><br />           <input type="hidden" id="total_amount" name="total_amount" value="0">

                  <div>
                  <fieldset class="fieldset">

                  <legend>Billetes</legend>
                  <div class="row_form_div">
                      <label for="hundred_amount">100</label>
                      <input type="text" id="hundred_amount" name="hundred_amount" class="billet"/>
                      <input type="hidden" id="hundred_denomination_id" name="hundred_denomination_id" value="1">
                  </div>

                  <div class="row_form_div">
                      <label for="fith_amount">50</label>
                      <input type="text" name="fith_amount" id="fith_amount"  class="billet"/>
                      <input type="hidden" id="fith_denomination_id" name="fith_denomination_id" value="2">
                  </div>

                  <div class="row_form_div">
                      <label for="twenty_amount">20</label>
                      <input type="text" name="twenty_amount" id="twenty_amount" class="billet"/>
                      <input type="hidden" id="twenty_denomination_id" name="twenty_denomination_id" value="3">
                  </div>

                  <div class="row_form_div">
                      <label for="ten_amount">10</label>
                      <input type="text" name="ten_amount" id="ten_amount" class="billet"/>
                      <input type="hidden" id="ten_denomination_id" name="ten_denomination_id" value="4">
                  </div>

                  <div class="row_form_div">
                      <label for="five_amount">5</label>
                      <input type="text" name="five_amount" id="five_amount" class="billet"/>
                      <input type="hidden" id="five_denomination_id" name="five_denomination_id" value="5">
                  </div>

                  <div class="row_form_div">
                      <label for="one_amount">1</label>
                      <input type="text" name="one_amount" id="one_amount" class="billet"/>
                      <input type="hidden" id="one_denomination_id" name="one_denomination_id" value="6">
                  </div>

                 </fieldset>
                 </div>
</form>

Before sending it I need to ask for a condition with the data of the form.
I build a jquery ui dialog to ask for the condition

<div id="dialog-confirm" title="&iquest;Cerrar turno con diferencia?">
            <p><span class="ui-icon ui-icon-alert" style="float:left; margin:0 7px 20px 0;">
            </span>El desglose insertado no coincide con el total por concepto de operaciones. Esto significa que cerrar&aacute; el turno con diferencia. 
            &iquest;Est&aacute; seguro?</p>
        </div>

That I call with the following JQuery code:

$( "#dialog-confirm" ).dialog({
    resizable: false,
    autoOpen:false,
    height:150,
    width:340,
    open:false,
    modal: true,
    buttons: {
        "No": function() {
            $( this ).dialog( "close" );
        },
        "Si": function() {
                $("#form").submit();
                $(this).dialog('close');
                }
        }
    }
});

This is with the aim to send the data posted in the form but nothings happens.

I have also tried to do this with Ajax

        "Si": function() {
                $("#form").submit();
                if (true) {
                    {
                        $.ajax({
                            type: "POST",
                            dataType: "json",
                            url: 'daily_operation/turn_close',
                            data: $("#form").serialize(), // serializes the form's elements.
                            success: function(data)
                            {
                            },
                            error: function(data) {
                                bValid = false;
                            }
                        });

                    }
                    $(this).dialog('close');
                }
        }

But remains without send nothing.

Could you please help me? Thanks in advance…

  • 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-13T20:07:41+00:00Added an answer on June 13, 2026 at 8:07 pm

    The question is if you are trying to send it traditional way or by using AJAX

    $("#form").submit();
    

    This should send it but there are some problems (eg. IE requires that form contains submit button sic!). And this approach can create many problems. What i suggest is to use AJAX. For start try and see what happens. :

    $.ajax({
                                type: "POST",
                                dataType: "json",
                                url: 'daily_operation/turn_close',
                                data: $("#form").serialize(), 
                                beforeSend : function(){
                                      alert($("#form").serialize());
                                },
                                success: function(data)
                                {
                                     alert(data);
                                },
                                error: function(data) {
                                    bValid = false;
                                }
                            });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have following Situation, Server A sends some data (HTML form) to server B,
I have the following form in a Struts2 JSP that contains some radio buttons.
I'm looking at some Java classes that have the following form: public abstract class
I need some help with something... say I have the following form... <form name=
I have the following form: @model Teesa.Models.SearchModel @using (Html.BeginForm(Index, Search, FormMethod.Get, new { id
I have the following data that I am trying to feed into a Handlebar
I have a html form and I need to get the form data in
We have some InfoPath (XSN) forms with code-behind hosted in MOSS that have data
Assuming I have some data in the form of Customer1 Name Address Order1 ID
I have the following two variables. I will send the data variable to 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.