I am trying to shift my radio button to the right for this certain part for a long time and it still doesn't work, I try using padding and class col-md for it and even check if my tag are closed but it is still not moving to the right. Can anybody help me with this problem? Thanks in advance.
test.blade.php
<div class="form-group">
<label class="col-md-2"><b>Residential Status:</b></label>
<div class="col-md-8">
<input type="radio" name="residential_status" value="Local" required> Local<br>
<input type="radio" name="residential_status" value="Overseas" required> Overseas<br>
</div>
</div>
<div class="form-group">
<div class="editfield1">
<div class="radio">
<div id="chkNRICid1">
<label style="font-weight: bold">Do you have a NRIC?</label> <br/>
<input type="radio" name="NRIC_check" id="nricid1" value="Yes" onclick="document.getElementById('NRIC_check').style.display='block'" required> Yes <br>
<input type="radio" name="NRIC_check" id="nricid2" value="No" onclick="document.getElementById('NRIC_check').style.display='none'" required> No
</div>
</div>
</div>
<div class="editfield1" id="NRIC_check" style="display:none">
<label for="NRIC_check"> Type your NRIC/FIN number:</label>
<label><input type="text" name="nric_number1" id="nric_number1"> </label>
</div>
</div>
This is the screenshot of what is happening: (I want it to be like the Residential Status)
So many wayward and un-needed divs you can get rid of along with fixing your nesting, after that it's just a matter of following the structure in the first part of your template:
<div class="form-group">
<div class="col-md-2">
<label>Residential Status</label>
</div>
<div class="col-md-10">
<label><input type="radio" name="residential_status" value="Local" required> Local</label>
<br />
<label><input type="radio" name="residential_status" value="Overseas" required> Overseas</label>
</div>
</div>
<div class="form-group">
<div class="col-md-2">
<label>Do you have a NRIC?</label>
</div>
<div class="col-md-10">
<label><input type="radio" name="NRIC_check" id="nricid1" value="Yes" onclick="document.getElementById('NRIC_check').style.display='block'" required>Yes</label>
<br />
<label><input type="radio" name="NRIC_check" id="nricid2" value="No" onclick="document.getElementById('NRIC_check').style.display='none'" required> No </label>
</div>
</div>
<div class="form-group" id="NRIC_check" style="display:none">
<div class="col-md-2">
<label>Type your NRIC/FIN number:</label>
</div>
<div class="col-md-10">
<input type="text" name="nric_number1" id="nric_number1" />
</div>
</div>
Wrap the two inputs inside a <div> and add some margin.
<div style="margin-left: 50px">
<input ... />
<input ... />
</div>
If you are using Bootstrap 4 you could even:
<div class="ml-5">
Related
When processing two forms on a page how do I prevent Undefined Index for a variable that has not been submitted?
I have a page with two forms and I am trying to send one of the forms to the server, but I keep getting variables from the other form as an undefined index.
<form id="dassets" class="d-none" action="process.php" method="post" enctype="multipart/form-data">
<div>
<label class="medium my-2" for="assetType">Type</label>
<input class="form-control my-2" name="coinName" id="assetType" type="text" placeholder="Card Selected" /readonly>
</div>
<div class="col px-0">
<!-- Get current BTC value in dollars -->
<div id="dataBTC" class="text-primary"></div>
<label class="medium my-2">Coin value</label>
<div class="input-group input-group-sm mb-3">
<div class="input-group-prepend">
<span class="input-group-text" id="coin-value">BTC</span>
</div>
<input type="text" class="form-control" name="quantity" aria-label="BTC" aria-describedby="coin-value">
</div>
</div>
<div class="form-group">
<div class="col px-0">
<label for="file01" class="my-2">Please upload a very clear photo of the payment receipt/gift card where necessary</label>
<div class="form-group mt-4">
<label for="file01">Upload a file</label>
<input type="file" class="form-control-file" id="file01">
</div>
</div>
<input type="hidden" name="action" value="BTC">
<input type="submit" class="btn btn-success btn-rounded px-3 mt-3" value="Trade" name="submit"/>
</div>
</div>
<!-- Card trade -->
<div class="col-xl-7 card-body d-none" id="dock">
Here is the second form; I added a hidden field to distinguish them:
<form id="amazonForm" class="d-none" action="" method="post" enctype="multipart/form-data">
<div>
<label for="cardType">Type</label>
<input class="form-control" id="typeAmazon" type="text" placeholder="Card Selected" name="ca2rdType" readonly/>
</div>
<div class="col px-0">
<label for="ctry" class="my-2">Country</label>
<select id="ctryAmazon" class="form-control" name="country">
<option selected>USD</option>
<option>EUR</option>
<option>CAD</option>
<option>GDP</option>
<option>CHF</option>
<option>AUD</option>
</select>
</div>
<div class="col px-0">
<label for="country" class="my-3">Select Gift Card Type</label>
<!--Amazon Gift Cards -->
<div id="amazonUsa" class="d-none">
<!-- Cash Receipt -->
<div class="custom-control custom-checkbox ">
<input type="checkbox" class="custom-control-input" id="amazonCash">
<label class="custom-control-label" for="amazonCash">Cash Receipt</label>
</div>
<!-- Debit Receipt -->
<div class="custom-control custom-checkbox">
<input type="checkbox" class="custom-control-input" id="amazonDebit">
<label class="custom-control-label" for="amazonDebit">Debit Receipt</label>
</div>
<!-- No Receipt -->
<div class="custom-control custom-checkbox">
<input type="checkbox" class="custom-control-input" id="noReceipt">
<label class="custom-control-label" for="noReceipt">No Receipt</label>
</div>
<!-- Ecode -->
<div class="custom-control custom-checkbox">
<input type="checkbox" class="custom-control-input" id="eCode">
<label class="custom-control-label" for="eCode">Ecode</label>
</div>
<!-- Physical -->
<div class="custom-control custom-checkbox">
<input type="checkbox" class="custom-control-input" id="physical">
<label class="custom-control-label" for="physical">Physical</label>
</div>
<!-- Large card -->
<div class="custom-control custom-checkbox">
<input type="checkbox" class="custom-control-input" id="largecard">
<label class="custom-control-label" for="largecard">Large Card</label>
</div>
</div>
<div class="form-group">
<div class="col d-md-flex justify-content-between px-0">
<div>
<label for="amount" class="my-3">Input card value amount</label>
<input class="form-control" id="amount" type="number" placeholder="Enter an amount"/>
</div>
<div>
<label for="equivalent" class="my-3">Equivalent in Naira</label>
<input class="form-control text-success" id="cashout" type="text" placeholder="Cashout in Naira" readonly/>
</div>
</div>
</div>
<div class="col px-0">
<label for="file02" class="my-2">Please upload a very clear photo of the payment receipt/giftcard</label>
<div class="form-group mt-4">
<label for="file01">Upload a file</label>
<input type="file" class="form-control-file" id="file02">
</div>
</div>
<input type="hidden" name="action" value="GTC">
<input type="submit" class="btn btn-success btn-rounded px-3 mt-3" value="Trade" name="submit_2"/>
</div>
</form>
Just use an if statement in your PHP to check if your variables exist before you use them, and if they are undefined then you can deal with that error in a cleaner fashion.
Give each submit button a different name i.e.
<input name='form1' type='summit' value='submit'>
<input name='form2' type='summit' value='submit'>
In php you can then use
if( isset($_POST['submit']) && $_POST['submit'] == 'form1' ) {
// do form1 stuff
} else if( isset($_POST['submit']) && $_POST['submit'] == 'form2' ) {
// do form 2 stuff
}
Try this at SERVER side (i.e. process.php):
if ($_POST['action'] == 'BTC') {
//action for BTChere
} else if ($_POST['action'] == 'GTC') {
//action for GTC
} else {
//invalid action!
}
Refer this answer
Still you have issue then try AJAX.
Also,
You miss action attribute from second form (it's empty).
If you want to submit to process.php then add in second form (No need to check action again)
or other file then add respective path (Need to check action i.e. $_POST['action'] is BTC or GTC).
By default,empty action submit redirect to same file.
Check this for details
Hope you get idea.
Can you show the php block, also are you checking isset("submit")? then since you know the particular action that was performed also check the isset the variables too.
If I click on one check box another check box also checked.
addquiz.php
<?php
$unique_id = time().'_'.uniqid(true);
$userid = $this->session->userdata('cp_userid');
?>
<!-- DC QUIZZ -->
<form class="addquizform" id="quiz_form_<?php echo $unique_id;?>" data-form = "<?php echo $unique_id;?>" data-user = '<?php echo $userid ?>'>
<input type="hidden" name="sid" value="<?php echo $sectionId;?>">
<input type="hidden" name="cid" value="<?php echo $courseId;?>">
<div class="dc-quizz-info dc-course-item">
<div class="dc-content-title">
<h5 class="xsm black">Quiz : Title of quiz</h5>
<div class="course-region-tool">
<input type="button" value = "Save" class="mc-btn-3 btn-style-1 savequiz save" id="save_quiz_<?php echo $unique_id;?>">
</div>
</div>
<div class="quizz-body dc-item-body">
<div class="form-item form-checkbox checkbox-style">
<input type="checkbox" id="showanswer" value="1" name="showanswer">
<label for="showanswer">
<i class="icon-checkbox icon md-check-1"></i>
Show Answer
</label>
</div>
<div class="form-item form-checkbox checkbox-style">
<input type="checkbox" id="limittime">
<label for="limittime">
<i class="icon-checkbox icon md-check-1"></i>
Limit time
</label>
</div>
<div class="time">
<div class="form-item">
<input type="text" name="limittime">
<label for="">mins</label>
</div>
</div>
<div class="form-item">
<input type="text" placeholder="Quiz Title" class="fullwidth" name="quiztitle">
</div>
<div class="form-item">
<input type="text" placeholder="Short introduction" class="fullwidth" name="quizintro">
</div>
</div>
</div>
</form>
<!-- END / DC QUIZZ -->
when I go to add one more quiz it asks to check the check box, but when I clicked on check box above check box also checked. How to over come this problem.
Please Check The Name as well as id You Defined there is missing an id and name for checkbox
<div class="dc-quizz-info dc-course-item">
<div class="dc-content-title">
<h5 class="xsm black">Quiz : Title of quiz</h5>
<div class="course-region-tool">
<input type="button" value = "Save" class="mc-btn-3 btn-style-1 savequiz save" id="save_quiz_<?php echo $unique_id;?>">
</div>
</div>
<div class="quizz-body dc-item-body">
<div class="form-item form-checkbox checkbox-style">
<input type="checkbox" id="showanswer" value="1" name="showanswer">
<label for="showanswer">
<i class="icon-checkbox icon md-check-1"></i>
Show Answer
</label>
</div>
<div class="form-item form-checkbox checkbox-style">
<input type="checkbox" name="limitcheck" id="limitcheck">
</div>
<div class="time">
<label for="limittime">
<i class="icon-checkbox icon md-check-1"></i>
Limit time
</label>
<div class="form-item">
<input type="text" value="" id="limittime" name="limittime">
<label for="">mins</label>
</div>
</div>
<div class="form-item">
<input type="text" placeholder="Quiz Title" class="fullwidth" name="quiztitle">
</div>
<div class="form-item">
<input type="text" placeholder="Short introduction" class="fullwidth" name="quizintro">
</div>
</div>
</div>
My nav-tabs works fine using static data for my dropdown list but when I add the script to populate the dropdown list, the tabs don't work anymore.
I don't think there's any problem with the query since the list gets populated. Probably with the echo?
<div class="nav-tabs-custom">
<ul class="nav nav-tabs">
<li class="active">Boarding House Info</li>
<li>Other Info</li>
<li>Location</li>
</ul>
<div class="tab-content">
<div class="tab-pane active" id="tab_1">
<div class="box-body">
<div class="form-group">
<label for="boarding-house-name">Boarding House Name</label>
<input type="text" class="form-control" id="bh-name" name="bh-name" placeholder="boarding house name">
</div>
<div class="form-group" style="margin-bottom:50px">
<label for="price">Price</label><br>
<div class="col-md-2" style="margin-left:-15px;">
<input type="text" class="form-control" id="pricemin" name="bh-pricemin" placeholder="min">
</div>
<div class="col-md-2" style="margin-left:-15px;">
<input type="text" class="form-control" id="pricemax" name="bh-pricemax" placeholder="max">
</div>
</div>
<div class="form-group">
<label for="address">Address</label>
<input type="text" class="form-control" id="address" name="bh-address" placeholder="address">
</div>
<div class="form-group">
<label for="barangay">Barangay</label>
<select class="form-control" name="bh-barangay">
<option value="Brgy 1">Brgy 1</option>
<option value="Brgy 2">Brgy 2</option>
<option value="Brgy 3">Brgy 3</option>
<option value="Brgy 4">Brgy 4</option>
</select>
</div>
<div class="form-group">
<label for="contactperson">Contact Person</label>
<input type="text" class="form-control" id="contactperson" name="bh-contactperson" placeholder="contact person">
</div>
<div class="form-group">
<label for="contactnumber">Contact Number</label>
<input type="text" class="form-control" id="contactnumber" name="bh-contactnumber" placeholder="contact number">
</div>
<div class="form-group">
<label for="owner">Owner</label>
<select class="form-control" name="bh-owner-id">
<?php
$query = "SELECT id_owner, owner_name FROM tbl_owner";
$result = $conn->query($query) or die("Connection failed: " . $conn->connect_error);
while($row = mysqli_fetch_assoc($result)) {
echo "<option value='".$row['id_owner']."'>".$row['owner_name']."</option>";
} mysql_free_result($result);
?>
</select>
</div>
</div>
</div>
<div class="tab-pane" id="tab_2">
<div class="box-body">
<div class="form-group">
<label for="tenant" style="margin-bottom:-15px;">Tenant</label>
<div class="checkbox">
<label class="checkbox-inline">
<input type="checkbox" id="tenant_checkbx" value="Male"> Male
</label>
<label class="checkbox-inline">
<input type="checkbox" id="tenant_checkbx" value="Female"> Female
</label>
</div>
</div>
<div class="form-group" style="margin-bottom:50px">
<label for="specification">Specification</label><br>
<div class="col-md-6" style="margin-left:-15px;">
<select class="form-control">
<option>Boarding House</option>
<option>Dormitory</option>
<option>Apartelle</option>
<option>Lodge</option>
<option>Motel</option>
</select>
</div>
</div>
<div class="form-group" style="margin-bottom:50px">
<label for="noofrooms">No. of Rooms</label><br>
<div class="col-md-6" style="margin-left:-15px;">
<input type="text" class="form-control" id="exampleInputEmail1" placeholder="# of rooms">
</div>
</div>
<div class="col-md-2">
<div class="form-group" style="margin-left:-15px;">
<label for="curfew">Curfew</label>
<div class="radio">
<label>
<input type="radio" name="curfew_radio" id="curfew_yes" value="Yes" checked> Yes
</label>
</div>
<div class="radio">
<label>
<input type="radio" name="curfew_radio" id="curfew_no" value="No"> No
</label>
</div>
</div>
</div>
<div class="col-md-2">
<div class="form-group" style="margin-left:-15px;">
<label for="guests">Guests</label>
<div class="radio">
<label>
<input type="radio" name="guests_radio" id="guests_yes" value="Yes" checked> Yes
</label>
</div>
<div class="radio">
<label>
<input type="radio" name="guests_radio" id="guests_no" value="No"> No
</label>
</div>
</div>
</div>
<div class="col-md-2">
<div class="form-group" style="margin-left:-15px;">
<label for="crtype">CR Type</label>
<div class="checkbox">
<label>
<input type="checkbox" id="crtype_checkbx" value="Private"> Private
</label>
</div>
<div class="checkbox">
<label>
<input type="checkbox" id="crtype_checkbx" value="Public"> Public
</label>
</div>
</div>
</div>
</div>
</div>
<div class="tab-pane" id="tab_3">
<div class="box-body">
<!-- INSERT MAP HERE -->
</div>
</div>
</div>
</div>
Here is the query php script I used to populate the owner dropdown list:
<?php
$query = "SELECT id_owner, owner_name FROM tbl_owner";
$result = $conn->query($query) or die("Connection failed: " . $conn->connect_error);
while($row = mysqli_fetch_assoc($result)) {
echo "<option value='".$row['id_owner']."'>".$row['owner_name']."</option>";
} mysql_free_result($result);
?>
It's working now. Did some more debugging with the script and it seems like the line:
mysql_free_result($result);
(after the while condition) is the culprit.
I removed it and the tabs are working now. :)
i am trying to get connected to database .html page doesnt get connected to addtodatabase.php which has many feilds like radio button,checkbox,textarea, input field .Once given submit it doesn't display the data .
<form action="addtodatabase.php" method="post">
<div class="container">
<form class="form-inline">
<fieldset>
<legend>Security Department User Registration</legend>
<div class="form-group">
<label for="Firstname">First Name</label>
<input type="text" class="form-control" id="Firstname" name="Firstname" placeholder="Text input"><br/>
</div>
<div class="form-group">
<label for="Secondname">Second Name</label>
<input type="text" class="form-control" id="Secondname" name="Secondname" placeholder="Text input"><br/>
</div>
</form>
.....
...
<button type="submit" class="btn btn-default">Submit</button>
addtodatabase.php page as phpmyadmin username as root , pasword NULL
<?php
$connection = mysql_connect ('root','','');
mysql_select_db('form_db');
$Firstname = $_POST ['Firstname'];
$Secondname = $_POST ['Secondname'];
echo $_POST['Firstname'];
echo '<br />';
echo $_POST['Secondname'];
$query =
"INSERT INTO form_details
(Firstname,Secondname)
values
('$Firstname','$Secondname')";
$result = mysql_query($query);
Echo "Database Saved";
mysql_close($connection);
?>
i have change the code from mysql to mysqli
<?php
$connect=mysqli_connect('localhost','root','','form_db');
if(mysqli_connect_errno($connect))
{
echo 'Failed to connect';
}
$Firstname = $_POST ['Firstname'];
$Secondname =$_POST ['Secondname'];
echo $_POST['Firstname'];
echo '<br />';
echo $_POST['Secondname'];
$query =
"INSERT INTO form_details
(Firstname,Secondname)
values
('$Firstname','$Secondname')";
$result = mysqli_query($query);
if(mysqli_affected_rows($connect) > 0){
echo "<p>Employee Added</p>";
echo "Go Back";
} else {
echo "Employee NOT Added<br />";
echo mysqli_error ($connect);
}
?>
Even after changing to mysqli it not working .addtodatabase.php
I am getting this error Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in C:\wamp64\www\Form\addtodatabase.php on line 2
My entire form looks this way
<!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" href="css/bootstrap.min.css">
<link rel="stylesheet" href="customstyle.css">
</head>
<body>
<script src="http://code.jquery.com/jquery-1.11.0.min.js"></script>
<script src="js/bootstrap.min.js"></script>
<form action="addtodatabase.php" method="post">
<div class="container">
<h1> Group of Companies</h1>
<h3> ICT & Security Department User Registration form </h3>
<h4> To be filled by HR department for New Employee </h4>
<form class="form-inline">
<fieldset>
<legend>Security Department User Registration</legend>
<div class="form-group">
<label for="Firstname">First Name</label>
<input type="text" class="form-control" id="Firstname" name="Firstname" placeholder="Text input"><br/>
</div>
<div class="form-group">
<label for="Secondname">Second Name</label>
<input type="text" class="form-control" id="Secondname" name="Secondname" placeholder="Text input"><br/>
</div>
</form>
<form >
<div class="form-group">
<label for="location">Dpt./Location</label>
<input type="text" class="form-control" name="location" id="location" placeholder="Text input">
</div>
</form>
<form class="form-inline">
<div class="form-group">
<label for="Designation">Designation</label>
<input type="text" class="form-control" id="Designation" placeholder="Text input"><br/>
</div>
<div class="form-group">
<label for="Fileno">File No</label>
<input type="text" class="form-control" id="Fileno" placeholder="Password"><br/>
</div>
</form>
<form class="form-inline">
<div class="form-group">
<label for="Dateofapplication">Date of Application</label>
<input type="text" class="form-control" id="Dateofapplication" placeholder="Text input"><br/>
</div>
<div class="form-group">
<label for="Dateofjoining">Date of Joining</label>
<input type="text" class="form-control" id="Dateofjoining" placeholder="Password"><br/>
</div>
</form>
<form>
<fieldset>
<legend>For Head office staffs only </legend>
<label>Card Type:</label>
<div id="idcard">
<label class="checkbox-inline">
<input type="checkbox" value="">Trainee ID Card
</label>
<label class="radio-inline">
<input type="radio" name="green">Green
</label>
<label class="radio-inline">
<input type="radio" name="red">Red
</label>
<label class="checkbox-inline">
<input type="checkbox" value="">Permanent ID Card
</label>
</div>
<div class="aligncheckbox">
<label>Door Access:</label>
<label class="checkbox-inline">
<input type="checkbox" value="">Main
</label>
<label class="checkbox-inline">
<input type="checkbox" value="">Finance Division
</label>
</div>
<div class="aligncheckbox">
<label class="checkbox-inline">
<input type="checkbox" value="">Meeting Room
</label>
<label class="checkbox-inline">
<input type="checkbox" value="">Goods Receiving
</label>
</div>
<div class="aligncheckbox">
<label class="checkbox-inline">
<input type="checkbox" value="">Graphics & Media
</label>
<label class="checkbox-inline">
<input type="checkbox" value="">IT Dept
</label>
</div>
<div class="aligncheckbox">
<label class="checkbox-inline">
<input type="checkbox" value="">Server Room
</label>
<label class="checkbox-inline">
<input type="checkbox" value="">Dist.&Quality Control
</label>
</div>
<div class="aligncheckbox">
<label class="checkbox-inline">
<input type="checkbox" value="">Warehouse Supervisor
</label>
<label class="checkbox-inline">
<input type="checkbox" value="">Pur.Office Meeting Room
</label>
</div>
<div class="aligncheckbox">
<label class="checkbox-inline">
<input type="checkbox" value="">Purchase Office
</label>
<label class="checkbox-inline">
<input type="checkbox" value="">Exit
</label>
</div>
<!-- <div class="upload">
<label for="Passportcopy">Passport Copy</label>
<input type="file" id="Passportcopy">
<label for="Photo">Photo</label>
<input type="file" id="Photo">
</div>
<div>
<label class="checkbox-inline">
<input type="checkbox" value="">Finger Registration
</label>
</div> -->
<div class="container">
<div id="upload row">
<form class="form-inline">
<div class="form-group col-xs-*">
<label for="Passportcopy">Passport Copy</label>
<input type="file" class="form-control" id="Passportcopy">
</div>
<div class="form-group col-xs-*">
<label for="Photo">Photo</label>
<input type="file" class="form-control" id="Photo">
</div>
</form>
</div>
</div>
</form>
<!-- second form IT department -->
<div class="secform">
<form>
<fieldset>
<legend>IT Department User Registration </legend>
<div class="container">
<form class="form-inline">
<div class="checkbox-inline" id="erp">
<label><input type="checkbox" value="">Enroll as sales Person ERP</label>
</div>
<div class="form-group" id="textbox">
<label for="erpmodules">ERP Modules</label>
<textarea class="form-control" rows="5" id="erpmodules"></textarea>
</div>
</fieldset>
</form>
<form>
<fieldset>
<legend>For Head office staffs only </legend>
<div class="fkhaccess">
<div class="form-group" id="textbox">
<label for="fkhaccess">FKH Folder Access</label>
<textarea class="form-control" rows="5" id="fkhaccess"></textarea>
</div>
<div class="container-fluid">
<ul id="access">
<li> <label>Internet Access</label></li>
<li>
<label class="radio-inline">
<input type="radio" name="yes">Yes
</label></li>
<li>
<label class="radio-inline">
<input type="radio" name="no">No
</label></li>
</ul>
<ul id="purpose">
<li><p>If yes, Purpose </p></li>
<li>
<div class="form-group" id="textbox">
<label for="purpose">Job Purpose</label>
<textarea class="form-control" rows="5" id="purpose"></textarea>
</div></li>
</ul>
<ul id="compmail">
<li>
<div class="form-group" id="textbox" >
<label for="companyemail">Company Email</label>
<textarea class="form-control" rows="5" id="companyemail"></textarea>
</div></li>
</ul>
<form class="form-inline">
<label> Computer facilities: </label>
<label> CD ROM </label>
<label class="checkbox-inline">
<input type="checkbox" value="">Read
</label>
<label class="checkbox-inline">
<input type="checkbox" value="">Write
</label>
<label> USB PORTS </label>
<label class="checkbox-inline">
<input type="checkbox" value="">Read
</label>
<label class="checkbox-inline">
<input type="checkbox" value="">Write
</label>
</form>
<form class="form-inline">
<label class="checkbox-inline" id="label1">
<input type="checkbox" value="">Parallel Port
</label>
</form>
<form class="form-inline">
<label> Printers </label>
<label class="checkbox-inline">
<input type="checkbox" value="">MP2352(Front Office)
</label>
<label class="checkbox-inline">
<input type="checkbox" value="">MP2501(Purchase)
</label>
</form>
<form class="form-inline">
<label class="checkbox-inline">
<input type="checkbox" value="">MP1600(MD Office)
</label>
<label class="checkbox-inline">
<input type="checkbox" value="">DSM616(Finance)
</label>
</form>
<form class="form-inline">
<ul><li>
<label> Computer Utilities :</label>
<label class="checkbox-inline">
<input type="checkbox" value="">Scanner
</label></li>
<li>
<label class="checkbox-inline">
<input type="checkbox" value="">Barcode Scanner
</label></li>
<li>
<label class="checkbox-inline">
<input type="checkbox" value="">Others
</label></li>
<ul id="software">
<li>
<div class="form-group" id="textbox" >
<label for="softwarerequired">Software Required </label>
<textarea class="form-control" rows="5" id="software"></textarea>
</div></li>
</ul>
</form>
</div>
</div>
</fieldset>
</form>
<div >
<div class="fill">
<div class='sign-container'>
<div class="div1">Form Filled by</div>
<div class='sign'> </div>
<div class="div2"> </div>
<div class="div3">(HR)</div>
</div>
</div>
<div class="sign-box">
<p id="signbox"> Signature </p>
<div class="div4"> </div>
<div class="fill">
<div class='sign-container'>
<div class="div1">Form Filled by</div>
<div class='sign'> </div>
<div class="div2"> </div>
<div class="div3">(Admin Manager)</div>
</div>
</div>
<div class="sign-box">
<p id="signbox"> Signature </p>
<div class="div4"> </div>
</div>
<div class="fill">
<div class='sign-container'>
<div class="div1">Form Filled by</div>
<div class='sign'> </div>
<div class="div2"> </div>
<div class="div3">(IT Manager)</div>
</div>
</div>
<div class="sign-box">
<p id="signbox"> Signature </p>
<div class="div4"> </div>
</div>
</div>
<div class="Threeform">
<form>
<fieldset>
<legend> User Confirmation </legend>
<div class="sign-container">
<div class="div1">User Name</div>
<div class='sign'> </div>
<div class="div1">System No</div>
<div class='sign'> </div>
</div>
<div class="policy-container">
<div class="div1">Received all the above mentioned facilities and understood international & FGC Cyber policy by
<div class='sign1'> </div></div>
</div>
<button type="submit" class="btn btn-default">Submit</button>
</form>
</div>
</form>
</div>
</body>
</html>
plz help me to rectify.
I am not able to connect from form.html page to addtodatabase.php .
Notice: Undefined index: firstname in C:\wamp64\www\Form\addtodatabase.php on line 12
You need to pass 2 parameters! $result = mysqli_query($connect, $query);
So i've updated the codes.
i'm trying to make a radio box so when yes is checked on the radio box a textbox appears using angular.js hoping it would work.
<div ng-app="">
<div class="form-group">
<label class="control-label col-sm-2">Experience:</label>
<div class="col-sm-2">
<input type="radio" name="emp_experience" ng-model="experience" value='
<div class="form-group">
<label class="control-label col-sm-2">Experience Years:</label>
<div class="col-sm-4">
<input type="text" name="emp_exp_y" class="form-control" placeholder="Years">
</div>
</div>'
required />Yes
</div>
<div class="col-sm-2">
<input type="radio" name="emp_experience" ng-model="experience" value=" " required />No
</div>
<?php $a = "{{experience}}";
echo <<<EOD $a
EOD;
?>
</div>
</div>
I want the output to generate a textbox when yes is clicked but all I get is the code itself
<div class="form-group"><div class="col-sm-4"><input type="text" name="emp_exp_y" class="form-control" placeholder="Years"> </div></div>