Why is my form not submitting or posting

Orenrocco

The form is not submitting or posting to the database with the connector.php. I have tried removing validation to no avail I do not know what is wrong. This issue has been bugging me for a day or two. Please help people.

`

<title>Sign up</title>
<link href="css/alldatcookies.css" rel="stylesheet" type="text/css" />
</head>

<body>
<nav class="nav ssm-nav-visible">
        <img src="img/swipe.png" alt="swipe image" width="73" height="85" align="right" />
        <p><img src="seventhswellicon10.png" width="178" height="169" align="middle" /></p>

           <ul>
<li><a class="" href="">Home</a></li>
<li><a href="">Login</a></li>
<li><a href="SignUp.html">Sign Up</a></li>
<li><span style="color: #FFFFFF"></span><a href="">Contact</a></li>
</ul>
</nav>

<form id="msform" name="msform" onSubmit="return checkForm(this)"         action="connector.php" method="POST" >
<a href="#" style="color:#FFFFFF" class="ssm-open-nav" title="open nav">Menu</a>
<ul id="progressbar">
    <li class="active">Account Setup</li>
    <li> Profile</li>
    <li>Personal Details</li>
    </ul>
    <fieldset>
    <h2 class="fs-title">Create your account</h2>
    <h3 class="fs-subtitle">Step 1</h3>
        <input id="username" name="username" placeholder="In Game Username"/>
    <input id="email" name="email" placeholder="email"/>
    <br />
    <input type="password" id="pass" name="pass" placeholder="Password" pattern="(?=.*\d)(?=.*[a-z])(?=.*[A-Z]).{6,}"onchange="form.cpass.pattern = this.value;">
   <br />   
   <input type="password" id="cpass" name="cpass" placeholder="Confirm Password" onKeyUp="checkPass(); return false;"  pattern="(?=.*\d)(?=.*[a-z])(?=.*[A-Z]).{6,}"/> <br />
    <input type="button" name="next" class="next action-button" value="Next" />
    </fieldset> <fieldset><h2 class="fs-title">Social Profiles</h2>
    <h3 class="fs-subtitle">Your presence on the social network</h3>
    <input type="text" name="twitter" placeholder="Twitter" />
    <input type="text" name="facebook" placeholder="Facebook" />
    <input type="text" name="gplus" placeholder="Google Plus" />
    <input type="button" name="previous" class="previous action-button" value="Previous" />   <input type="button" name="next" class="next action-button" value="Next" />   </fieldset>
    <fieldset>
    <h2 class="fs-title">Personal Details    </h2>
     <input type="text" id="firstname" name="firstname" placeholder="First Name" value="" /><br />
      <br />
    <input type="text" id="lastname" name="lastname" placeholder="Last Name" />
     <br />
     <input type="tel" id="phone" name="phone" placeholder="Phone" />
     <br />
     </textarea> 
      <input type="button" name="previous" class="previous action-button" value="Previous" />
      <input type="submit" name="submit" id="msform"class="submit action-button" value="Submit"/>
      </fieldset>
      </form>
      <script language="javascript">function validateForm()
      {
      var x=document.forms["msform"]["firstname"].value;
      if (x==null || x=="")
      {
      writeError("First name must be filled out");
      return false;  }
      return true
      }
      function validateForm()
      {
      var x=document.forms["msform"]["lastname"].value;
      if (x==null || x=="")
      {
      writeError("Last name must be filled out");
      return false;
      }
      return true
      }
      function validateForm() 
      {re = /[1-10]/;
      var x=document.forms["msform"]["phone"].value;
      if (x==null || x=="")
      {
      writeError("Phone number must be filled out");
      return false;
      }
      else
      {
      if(!re.test(document.forms["msform"]["phone"].value)) {
       writeError("Phone must at least contain 10 numbers ex. 1234567890!");
      document.forms["msform"]["phone"].focus();
      return false;
      }
      return true
      }
      }
      function validateForm()
      {
      var x=document.forms["msform"]["username"].value;
      if (x==null || x=="")
      {
      writeError("Username must be filled out");
       return false;
       }
       re = /^\w+$/;
       if(!re.test(document.forms["msform"]["username"].value)) {
       $(this).w2tag.alert("Username must contain only letters, numbers and     underscores!");
       document.forms["msform"]["username"].focus();
       return false;
       }
       return true
       }
       function validateForm()
       {
       var x=document.forms["msform"]["email"].value;
       var atpos=x.indexOf("@");
       var dotpos=x.lastIndexOf(".");
       if (atpos<1 || dotpos<atpos+2 || dotpos+2>=x.length)
       {
        writeError("Not a valid e-mail address");

          return false;
        }
        return true

        }

        function checkPass()

        {

        //Store the password field objects into variables ...

        var pass1 = document.getElementById('pass');

        var pass2 = document.getElementById('cpass');

        //Store the Confimation Message Object ...

        var message = document.getElementById('confirmMessage');

        //Set the colors we will be using ...

        var goodColor = "#66cc66";

        var badColor = "#ff6666";

        //Compare the values in the password field 

        //and the confirmation field

        if(pass1.value == pass2.value){

        //The passwords match. 

        //Set the color to the good color and inform

        //the user that they have entered the correct password 

        pass2.style.backgroundColor = goodColor;

        message.style.color = goodColor;

        message.w2tag = "Passwords Match!";

        }else{

        return false

        {

        //The passwords do not match.

       //Set the color to the bad color and

 //notify the user.

        pass2.style.backgroundColor = badColor;

        message.style.color = badColor;

        message.w2tag = "Passwords Do Not Match!";

        }

        return true

        } 

        }

        </script> 

        <style type="text/css">

        {}options: {

        css    : {,    ;// css rules for input

        class  : '',    ;// class name for input

        onShow : null,  ;// function to execute when overlay is shown 

        onHide : null   ;// function to execute when overlay is hidden 

        }

        </style>

        <!-- jQuery -->


     <script src="Javascript/jquery-2.1.0.min.js" type="text/javascript">                     </script>


        <!-- jQuery easing plugin -->
        <script src="Javascript/jquery.easing.min.js" type="text/javascript"></script>

        <script src="css/cookiemonster.js" type="text/javascript"></script>                 

     <script 

             src="http://labs.rampinteractive.co.uk/touchSwipe/jquery.touchSwipe.min.js">  

   </script>

    <script src="jquery.slideandswipe.min.js"></script>

    <div class="ssm-overlay"></div>


    <script>

       $(document).ready(function() {

            $('.nav').slideAndSwipe();

     });

         </script>



      </body>

      </html>`
user987654321

It doesn't appear that you have anything in your script that activates it. Typically you want a script to start on a click or something like that... your code doesn't appear to have any events to trigger the functions.

Take a look at this site that demonstrates enabling a submit button with .addEvent.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

Why is my multiple select form field only submitting one value Django?

Why won't my form upload to my database? after submitting the databse is still empty

Why is Redux Form not setting the value for submitting?

Why is this form not posting data?

Why is my data not posting to the listbox?

Jquery submit() not submitting form data to my view

Why is this button not submitting my form? ASP.NET MVC

Why is my submit button not submitting form data? - HTML/Node

Why are unchecked checkboxses ignored when posting a form?

My react form is not submitting correctly

my arrays/select are not posting with my form

Why is my form not submitting data to update my database?

why this form is not submitting?

Why does preventDefault() of a click event also prevent my form from submitting?

Submitting a form sends blank values to API, why?

PHP: Posting a tweet on submitting a form

Bootstrap modal submitting my form

Why is my form not posting to the pivot table?

Why is my javascript form not submitting?

Why isn't my form submitting

Why is my form posting after ajax post? How do I fix this?

Why is my jQuery Bootstrap form not submitting clean JSON to the REST service?

changing my JSON data when submitting form

Why is my form is POSTING multiple times and Socket emitting multiple events?

Weird question but why is my Form submitting when I did not click on the button

Why are my stepUp/stepDown buttons submitting the form with each click

Why's my POST request turning into a GET request upon submitting the form?

Why is my PHP page submitting a form through the page that redirected it?

PHP submitting a form is destroying my sessions