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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T07:19:56+00:00 2026-06-18T07:19:56+00:00

I tried many times and visited many forums but couldn’t find the answer. Please

  • 0

I tried many times and visited many forums but couldn’t find the answer. Please do not post it is similar like some other post. Just try to help me to fix this.

HTML Form:

<form action="" method="post" id="bookingForm">
<div id="radiobutton">
<input type="radio" name="trip" id="oneway" value="oneway" checked/>&nbsp;Oneway
<input type="radio" name="trip" id="return" value="return"/>&nbsp;Return
</div>
<br/>

From:<input id="boarding" type="text" maxlength="40" class="user_input" size="18" name="boarding" value="Hyderabad"/>
To:<input id="landing" type="text" maxlength="40" class="user_input" size="18" name="landing"/>
<br/><br/><br/>

Onward:<input id="datepick"  name="onward" class="user_input" size="15" />

Return: <input id="datepick2"  name="return" class="user_input" size="15" />
<br/><br/><br/>
Your Name:<input id="pax_name" type="text" name="pax_name"  class="user_input" size="25" maxlength="50"/>
<br/><br/>
Contact number:<input id="pax_contact" type="text" maxlength="14" name="pax_contact" class="user_input" size="25"/>
<br/><br/>
Email:<input id="pax_email" name="pax_email" class="user_input" size="25"/>
<br/><br/>
<center>

<input id="submit" type="button" value="Request" />

process.php for sending email:

<?php

  $trip=$_POST['trip'];
  $boarding=$_POST['boarding'];
  $landing=$_POST['landing'];
  $onward=$_POST['onward'];
  $return=$_POST['return'];
  $pax_name=$_POST['pax_name'];
  $pax_contact=$_POST['pax_contact'];
  $pax_email=$_POST['pax_email'];

        $to='anvesh@bsbtravels.com,anvifriend@gmail.com';
        $subject='Booking Form Query';
        $body=
              'Name: '.$pax_name."\n".
              'Contact Number: '.$pax_contact."\n".
              'Trip: '.$trip."\n".
              'From: '.$boarding."\n".
              'To: '.$landing."\n".
              'Onward Date: '.$onward."\n".
              'Return Date: '.$return."\n";
        $headers='From: '.$pax_name.'<'.$pax_email.'>';
        mail($to,$subject, $body, $headers)

?>

Jquery code:

$(document).ready(function(){
$('#submit').click(function(){
          var boarding=$('#boarding').val();
          var landing=$('#landing').val();
          var datepick=$('#datepick').val();
          var datepick2=$('#datepick2').val();
          var pax_name=$('#pax_name').val();
          var pax_contact=$('#pax_contact').val();
          var pax_email=$('#pax_email').val();


    if($('#landing').val().length<3 || $('#boarding').val().length<3 || $('#datepick').val().length<3 || $('#pax_name').val().length<3 || $('#pax_contact').val().length<8 || $('#pax_email').val().length<3){

        $('#bookfail').attr('title','Sending Failed!').text('Please Enter valid information. All fields are required').dialog({buttons:{'Ok':function(){
            $(this).dialog('close');
            }},closeOnEscape:true,draggable:false,resizable:false,modal:true});

    }else{
                var VarData='boarding='+boarding+'&landing='+landing+'&datepick='+datepick+'&datepick2='+datepick2+'&pax_name='+pax_name+'&pax_contact='+pax_contact+'&pax_email='+pax_email;
        $.ajax({
           type:'POST',
           url:'process.php',
                   data:VarData,
           success:function(){
           $('#booksuccess').attr('title','Request sent successfully').text('Your request has been sent. We will be in touch soon').dialog({buttons:{'Ok':function(){   $(this).dialog('close');
            }},closeOnEscape:true,draggable:false,resizable:false,modal:true});
           }
           error:function(){
                alert('Oops request sending failed. Please try again');
           }
        });
        }
    });
});
  • 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-18T07:19:58+00:00Added an answer on June 18, 2026 at 7:19 am

    You are missing a comma after your success callback:

    success:function(){
       ...
    }
    error:function(){
       ...
    }
    

    has to be

    success:function(){
       ...
    },// <--
    error:function(){
       ...
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Hello friends I have tried many times but I am not successful than please
I know similar questions have been asked before, but I've tried many times and
I have tried many times to do this, but it has not worked out
I tried decoding this base64 string so many times but every time i get
I tried many many times but nothing... I've a image on top of screen,
I have tried many times to aligh the elements in my RelativeLayout but I
Similar question has been asked many times. But I still don't get why I
I have tried many times to understand the const keyword, but it just doesn't
Over the years, I have tried many times to find a good, easy to
tried this many times but I just can't figure out how to define custom

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.