Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>ewedding</title>
<link href="source.css" rel="stylesheet" type="text/css" />
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
<script type="text/javascript" src="script.js"></script>
<script type="text/javascript" src="jquery.validate.min.js"></script>
<link rel="stylesheet" type="text/css" href="styles.css">
<link rel="stylesheet" type="text/css" href="bootstrap.css">
<style>
body {
    background-color: #C6F5F2;
}
#content {
    background-color:#C6F5F2;
    width:950px;
    min-height:550px;
    text-align:left;
    padding:20px;
}
h1 {
    padding:20px 10px 20px 10px;
}
h2 {
    padding-left: 0px !important;
}
#header {
    background-color: #CA410B !important;
}
.large {
    font-size:22px;
}
.orange {
    color:orange;
}
.italic {
    font-style:italic
}
.textmiddle {
    vertical-align:middle;
}
.padout {
    padding-left:25px;
    padding-right:25px;
}
.rounded-corners {
    -moz-border-radius: 40px;
    -webkit-border-radius: 40px;
    -khtml-border-radius: 40px;
    border-radius: 40px;
}
.rounded-corners-top {
    -moz-border-top-radius: 40px;
    -webkit-border-radius: 40px;
    -khtml-border-radius: 40px;
    border-radius: 40px;
}
.right {
    float: right;
}
.scrolldown {
    padding-left:20px;
    color:#EDECE8;
    font-size:40px;
    font-weight:bold;
    vertical-align:middle;
    text-shadow: #6374AB 2px 2px 2px;
}
.contentblock {
    margin: 0px 20px;
}
.results {
    border: 1px solid blue;
    padding:20px;
    margin-top:20px;
    min-height:50px;
}
.blue-bold {
    font-size:18px;
    font-weight:bold;
    color:blue;
}
/* example styles for validation form demo */
#register-form {
    background: url("form-fieldset.gif") repeat-x scroll left bottom #F8FDEF;
    border: 1px solid #DFDCDC;
    border-radius: 15px 15px 15px 15px;
    display: inline-block;
    margin-bottom: 30px;
    margin-left: 20px;
    margin-top: 10px;
    padding: 25px 50px 10px;
    width: 350px;
}
#register-form .fieldgroup {
    background: url("form-divider.gif") repeat-x scroll left top transparent;
    display: inline-block;
    padding: 8px 10px;
    width: 340px;
}
#register-form .fieldgroup label {
    float: left;
    padding: 15px 0 0;
    text-align: right;
    width: 110px;
}
#register-form .fieldgroup input, #register-form .fieldgroup textarea, #register-form .fieldgroup select {
    float: right;
    margin: 10px 0;
    height: 25px;
}
#register-form .submit {
    padding: 10px;
    width: 220px;
    height: 40px !important;
}
#register-form .fieldgroup label.error {
    color: #FB3A3A;
    display: inline-block;
    margin: 4px 0 5px 125px;
    padding: 0;
    text-align: left;
    width: 220px;
}
</style>
<script type="text/javascript">
/**
  * Basic jQuery Validation Form Demo Code
  * Copyright Sam Deering 2012
  * Licence: http://www.jquery4u.com/license/
  */
(function($,W,D)
{
    var JQUERY4U = {};

    JQUERY4U.UTIL =
    {
        setupFormValidation: function()
        {
            //form validation rules
            $("#register-form").validate({
                rules: {
                    first: "required",
                    last: "required",
                    email: {
                        required: true,
                        email: true
                    },
                   pno: "required",
                    add: "required",
                    city: "required",
                    state: "required",
                    agree: "required"
                },
                messages: {
                    first: "Please enter your firstname",
                    last: "Please enter your lastname",
                    email: "Please enter a valid email address",
                    pno:"Please your contact number",
                    add:"Please your address",
                    city:"Please enter your city",
                    state:"Please enter your state",
                    agree: "Please accept our policy"
                },
                submitHandler: function(form) {
                    form.submit();
                }
            });
        }
    }

    //when the dom has loaded setup form validation rules
    $(D).ready(function($) {
        JQUERY4U.UTIL.setupFormValidation();
    });

})(jQuery, window, document);
</script>
</head>

<body>
<?php
//FTP Host :-- ftp.webdesignerexperts.com
error_reporting(5);
$host="localhost";
$username="root";
$password="";
$database="ewedding";

$con=mysql_connect($host,$username,$password) or die("connect to the database");
$link=mysql_select_db($database,$con);
?>
<body>
<?php
if (isset($_REQUEST['submit'])) {
$first = $_POST['first'];
$last = $_POST['last'];
$email = $_POST['email'];
$pno = $_POST['pno'];
$add = $_POST['add'];
$city= $_POST['city'];
$state= $_POST['state'];
/* insert values in database */
$sql="INSERT INTO register_form (first,last,email,pno,add,city,state) VALUES ('".$first."', '".$last."', '".$email."','".$pno."', '".$add."', '".$city."', '".$state."')";
$qry=mysql_query($sql);

if($qry)
{

$emailmsg="Thanx for showing your interest in ______.com, your profile has been successfully created and will be live after approval from Admin";
}
}
?>

<?php include "includes/header.php" ?>
<h2 style="color:#2C97AE";>Client Register</h2>

<form name="register-form"  method="post" onsubmit=""  action=""    id="register-form" novalidate="novalidate" >
  <div id="form-content">
   <h3 style="color:#2C97AE";>Choose the type of vendor you are</h3>
      <select>
        <option selected="selected">--choose any one of them--</option>
        <option value="1">User</option>
        <option value="2"><a href="vendor.php">Vendor</a></option>
      </select>
      <p></p>
    <label>First name<span style="color:#F00">*</span></label>
    <input type="text" name="first" id="first" />
    <br />
    <label>Last name<span style="color:#F00">*</span></label>
    <input type="text" name="last" id="last" />
    <br />
    <label>Email<span style="color:#F00">*</span></label>
    <input type="text" name="email" id="email" />
    <br />
    <label>Contact number<span style="color:#F00">*</span></label>
    <input type="text" name="pno" id="pno" />
    <br />
    <label>Address<span style="color:#F00">*</span></label>
    <input type="text" name="add" id="add" />
    <br />
    <label>City<span style="color:#F00">*</span></label>
    <input type="text" name="city" id="city" />
    <br />
    <label>State<span style="color:#F00">*</span></label>
    <input type="text" name="state" id="state" />
    <br />
    <input type="submit" value="Create my account" name="submit" id="submit" class="submit"/>
  </div>
</form>
<?php include "includes/footer.php" ?>
</body>
</html>

share|improve this question

closed as off topic by Tachyons, devav2, Rinzwind, hexafraction, Mitch Oct 26 '12 at 15:12

Questions on Ask Ubuntu are expected to relate to Ubuntu within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

    
Can you provide a more complete question, or more details? –  david6 Oct 26 '12 at 8:49
    
Please migrate this to Stack Overflow. –  Evandro Silva Oct 26 '12 at 9:15
1  
Just for future reference, if you want to ask about programming, use Stack Overflow. However, they seem to be a bit critical of questions. Sorry. –  hexafraction Oct 26 '12 at 12:03

Browse other questions tagged or ask your own question.