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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T10:19:06+00:00 2026-06-05T10:19:06+00:00

I was writing a signup script when I received this error. Also, I want

  • 0

I was writing a signup script when I received this error. Also, I want to extend my knowledge iwith respect to this particular error. Endless Googling==> NO help. Here’s my code:

<?php
          //include the connection file

          require_once("functions/validation_employee_signup.php");
          require_once("functions/functions.php")

    if( isset($_POST['send']) && (!validateName($_POST['name']) || !validateEmail($_POST['email']) || !validatePasswords($_POST['pass1'], $_POST['pass2']) || !validateContact($_POST['contact']) || !validateAge($_POST['age'])) ):?>
                <div id="error">    
                    <ul>
                        <? if(!validateName($_POST['name'])):?>
                            <li><strong>Invalid Name:</strong> We want names with more than 3 letters.</li>
                        <? endif?>
                        <? if(!validateEmail($_POST['email'])):?>
                            <li><strong>Invalid E-mail:</strong> Type a valid e-mail please.</li>
                        <? endif?>
                        <? if(!validatePasswords($_POST['pass1'], $_POST['pass2'])):?>
                            <li><strong>Passwords are invalid:</strong> Passwords doesnt match or are invalid!</li>
                        <? endif?>
                        <? if(!validateContact($_POST['contact'])):?>
                            <li><strong>Please enter a valid number.</strong></li>
                        <? endif?>
                        <? if(!validateAge($_POST['age'])):?>
                            <li><strong>Please enter a valid age</strong></li>
                        <? endif?>
                        </ul>
                </div>
            <?php elseif(isset($_POST['send'])):?>
                <div id="error" class="valid">
                    <ul>
                    <?php
                    require_once('functions/connection.php'); 
                    $query = "INSERT INTO employee (name, password, email, contact, age, gender, location, skill, work) VALUES ";                
                    $email = protect($_POST['email']);
                    $res = mysql_query("SELECT * FROM `employee` WHERE `email` = '".$email."'");
                    $num = mysql_num_rows($res);
                    if($num == 1){
                            //if yes the username is taken so display error message
                            echo  "<li><strong>The EMail ID you have chosen is already taken!</strong></li>";
                                }else{           
                                $query .= "('".$_POST['name']."', MD5('".$_POST['pass1']."'), '".$email."','".$_POST['contact']."','".$_POST['age']."','".$_POST['gender']."','".$_POST['location']."','".$_POST['skill']."','".$_POST['work']."')";
                    // run the query
                    mysql_query($query);}?>
                    <li><strong>Congratulations!</strong> You have been successfully registered!</li>
                    </ul>
                </div>
        <?php endif?>
  • 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-05T10:19:07+00:00Added an answer on June 5, 2026 at 10:19 am

    Obviously it doesn’t expect the if statement, and it appears you forgot a semi-colon on row 5.

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

Sidebar

Related Questions

Writing a python program, and I came up with this error while using the
Writing Junit Tests for my spring application. Because I am new at this I
I'm writing a sign up form, and I have this: <?php for($j = 1;
I wrote this simple program: void sig_ha(int signum) { cout<<received SIGINT\n; } int main()
Writing an iPhone app in which I want to save the user the grief
I am writing a script to remove git commit tags (eg Signed-off-by:, Reviewed-by: )
I've successfully installed this jQuery-based signup form here: http://net.tutsplus.com/tutorials/javascript-ajax/building-a-sleek-ajax-signup-form/ But when I applied it
Writing something like this using the loki library , typedef Functor<void> BitButtonPushHandler; throws a
I am writing a login script for my website. I've written the login script,
I'm writing a sign up script, the users password is encrypted like so $pword

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.