Results 1 to 10 of 44
Threaded View
-
30th Mar 2012, 02:55 PM #36OPMemberWebsite's:
heroturko.biz softpk.com gfxtra.biz hotfilegfx.comtype is not show i am submit form but show Arry is not type name
Please check checkbox
Form Code:
PHP Code:<div class="toggle_container">
<div class="block">
<form enctype="multipart/form-data" action="add.php" method="POST">
<center><b><h7>Vendor Service Request</h7></b></center>
<div class="columns clearfix">
<div class="col_50">
<fieldset>
<label class="hospitalname">Hospital Name</label>
<div>
<input type="text" name="hospname" class="long">
</div>
</fieldset>
</div>
<div class="col_50">
<fieldset>
<label>Ref No.</label>
<div>
<input type="text" name="refno" class="long">
</div>
</fieldset>
</div>
</div>
<div class="columns clearfix">
<div class="col_50">
<fieldset>
<label>From</label>
<div>
<input type="text" name="from" class="long">
</div>
</fieldset>
</div>
<div class="col_50">
<fieldset>
<label>Description</label>
<div>
<input type="text" name="description" class="long">
</div>
</fieldset>
</div>
</div>
<div class="columns clearfix">
<div class="col_50">
<fieldset>
<label>Designation</label>
<div>
<input type="text" name="designation" class="long">
</div>
</fieldset>
</div>
<div class="col_50">
<fieldset>
<label>Manufacture</label>
<div>
<input type="text" name="manufacture" class="long">
</div>
</fieldset>
</div>
</div>
<div class="columns clearfix">
<div class="col_50">
<fieldset>
<label>Tel Number</label>
<div>
<input type="text" name="telnumb" class="long">
</div>
</fieldset>
</div>
<div class="col_50">
<fieldset>
<label>Models</label>
<div>
<input type="text" name="models" class="long">
</div>
</fieldset>
</div>
</div>
<div class="columns clearfix">
<div class="col_50">
<fieldset>
<label>Mobile Number</label>
<div>
<input type="text" name="mobnumb" class="long">
</div>
</fieldset>
</div>
<div class="col_50">
<fieldset>
<label>Serial numbers</label>
<div>
<input type="text" name="serialnumb" class="long">
</div>
</fieldset>
</div>
</div>
<div class="columns clearfix">
<div class="col_50">
<fieldset>
<label>Fax</label>
<div>
<input type="text" name="fax" class="long">
</div>
</fieldset>
</div>
<div class="col_50">
<fieldset>
<label>Equipment</label>
<div>
<input type="text" name="equipment" class="long">
</div>
</fieldset>
</div>
</div>
<div class="columns clearfix">
<div class="col_50">
<fieldset>
<label>Email address</label>
<div>
<input type="text" name="emailadd" class="long">
</div>
</fieldset>
</div>
<div class="col_50">
<fieldset>
<label class="attachment">Attachement</label>
<div>
<input type="file" id="fileupload2" name="attachement" class="uniform">
</div>
</fieldset>
</div>
</div>
<div class="columns clearfix">
<div class="col_50">
<fieldset>
<label>Type</label>
<div class="uniform">
<label for="yes">
<input type="checkbox" name="type[]" value="AG" id="yes"/>
Warranty
</label>
<label for="no">
<input type="checkbox" name="type[]" value="GE" id="no"/>
PPM Contact
</label>
<label for="cant">
<input type="checkbox" name="type[]" value="BR" id="no"/>
Repair argent
</label>
</fieldset>
</div>
<div class="col_50">
<fieldset>
<label>Fault Description And Service Description</label>
<div>
<textarea height="50px" name="faultdsd" class="long"></textarea>
</div>
</fieldset>
</div>
</div>
<div class="padding_10">
<button type="submit" value="Add" class="button blue"> <img src="images/icons/white/png/checkmark_icon&16.png" /> Submit </button>
<div class="clear"></div><!-- CLEAR BOTH -->
</div>
</form>
</div>
</div>
</div>
add.php
PHP Code:<?php
//This is the directory where images will be saved
$target = "vendor-req-service/";
$target = $target . basename( $_FILES['attachement']['name']);
if(isset($_POST['type']))
{
foreach($_POST['type'] as $value) {
$insert="INSERT INTO type (type) VALUES ('$value')";
mysql_query($insert);
}
}
//This gets all the other information from the form
$id=$_POST['ClientID'];
$hospname=$_POST['hospname'];
$refno=$_POST['refno'];
$from=$_POST['from'];
$description=$_POST['description'];
$designation=$_POST['designation'];
$manufacture=$_POST['manufacture'];
$telnumb=$_POST['telnumb'];
$models=$_POST['models'];
$mobnumb=$_POST['mobnumb'];
$serialnumb=$_POST['serialnumb'];
$fax=$_POST['fax'];
$equipment=$_POST['equipment'];
$emailadd=$_POST['emailadd'];
$insert=$_POST['type'];
$faultdsd=$_POST['faultdsd'];
$pic=($_FILES['attachement']['name']);
// Connects to your Database
mysql_connect("localhost", "username", "password") or die(mysql_error()) ;
mysql_select_db("my_db") or die(mysql_error()) ;
//Writes the information to the database
mysql_query("INSERT INTO `vendor` VALUES ('$id', '$hospname', '$refno', '$from', '$description', '$designation', '$manufacture', '$telnumb', '$models', '$mobnumb', '$serialnumb', '$fax', '$equipment', '$emailadd', '$pic', '$insert', '$faultdsd')") ;
//Writes the photo to the server
if(move_uploaded_file($_FILES['attachement']['tmp_name'], $target))
{
//Tells you if its all ok
echo "The file ". basename( $_FILES['uploadedfile']['name']). " has been uploaded, and your information has been added to the directory";
}
else {
//Gives and error if its not
echo "Sorry, there was a problem uploading your file.";
}
?>
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Similar Threads
-
[Selling] Excellent Matrimonial Script| Complete readymade Matrimony Script Available
By matriscript4u in forum Marketplace (Buy, Sell and Trade)Replies: 0Last Post: 23rd Oct 2012, 02:54 PM -
[Selling] Mp3 Search Engine, File Host, SMS Script, Arcade Script, PDF Search Script, and More!
By Fileze in forum Completed TransactionsReplies: 12Last Post: 13th Mar 2012, 02:23 PM -
Greasemonkey script: Megaupload Premium Multifetch Script
By Dman in forum Webmaster ResourcesReplies: 46Last Post: 15th Dec 2011, 01:07 AM -
[Selling] Rslinkgens Premium link generator script V1 -Most advanced and viral script
By vccshopper in forum Completed TransactionsReplies: 0Last Post: 24th Jun 2011, 08:10 PM -
[Selling] A.A.S. (Adult Automated Script For ClipBucket Video Script)
By tangi in forum Completed TransactionsReplies: 0Last Post: 25th Mar 2011, 12:45 PM
themaManager - edit and manage...
Version 4.18 released. Open older version (or...