Copy and Paste  -   An Application to Copy/Paste Text  

 
S.No 4731 Name database Date/Time 28-Dec-2021 05:09:53 PM

Copy text from below

<!doctype html>

<html>

<head>

<meta charset="utf-8">

<title>Untitled Document</title>

<style>

table,td

{

border: 1px solid #000000;

border-collapse: collapse;

padding: 4px;

}

</style>

</head>

 

<body>

<?php

require("opendb.php");

$status=true;

$mail="";

if(isset($_POST['sub']))

{

$fname = $_POST['f_name'];

$lname = $_POST['l_name'];

$mail = $_POST['mail'];

$id = $_POST['id'];

$gender = $_POST['gender'];

$country = $_POST['country'];

$address = $_POST['addr'];

$subject = $_POST["subject"];

try

{

$stmt = $conn->prepare("insert into information(id, first_name, last_name, email, Gender, Country, Address) values(:id, :fname, :lname, :mail, :gender, :country, :address)");

 

$stmt-> bindParam(':fname', $fname);

$stmt-> bindParam(':lname', $lname);

$stmt-> bindParam(':mail', $mail);

$stmt-> bindParam(':id', $id);

$stmt->bindParam(':gender', $gender);

$stmt->bindParam(':country', $country);

$stmt->bindParam(':address', $address);

$stmt -> execute();

$count = $stmt->rowCount();

echo "Number of rows: $count <br>";

}

catch(PDOException $e)

{

echo "Error: " . $e->getMessage();

$status = false;

}

finally

{

try

{

if( $status  == true)

{

$stmt = $conn->prepare("insert into subject (subjectname, femail) values (:subjectname, :femail)");

 

 

foreach($subject as $key=>$value)

{

$stmt-> bindParam(':subjectname', $value);

$stmt-> bindParam(':femail', $mail);

 

$stmt -> execute();

 

}

}

}

catch(PDOException $ex)

{

echo $e -> getMessage();

}

}

}

$conn = null;

?>

<form  method="post" action="">

<table>

<tr>

<td>

Email: <input type="email" name="mail" >

</td>

<td>

ID: <input type="text" name="id" >

</td>

</tr>

<tr>

<td>

Firt Name: <input type="text" name="f_name" >

</td>

<td>

Last Name: <input type="text" name="l_name" >

</td>

</tr>

<td>

Gender <input type="radio" name="gender" value="male">Male

<input type="radio" name="gender" value="female">Female

</td>

<td>

Country <select name="country">

<option> </option>

<option value="Pakistan">Pakistan</option>

<option value="Turkey">Turkey</option>

<option value="Iran">Iran</option>

</select>

</td>

<tr>

<td>

Subject <br>

<input id="subject[]" name="subject[]" type="checkbox" value="Physics">phy

<input id="subject[]" name="subject[]" value="Chemistry" type="checkbox" >chem

<input id="subject[]" name="subject[]" value="Biology" type="checkbox">bio

</td>

<td>

Address<input type="text" name="addr">

</td>

</tr>

<td>

<input type="submit" name="sub" value="submit">

</td>

</tr>

</table>

</form>

</body>

</html>





comments powered by Disqus
NEW ENTRIES
S.No Name Entry Time/Date
4957 KIDDO VIDEOS 15-Aug-2022 07:46:24 AM
4956 She♥Her 13-Aug-2022 07:16:51 AM
4955 Test 12 Eve 11-Aug-2022 11:20:00 AM
4954 Test 11 Eve 11-Aug-2022 11:18:05 AM
4953 Test 8 Eve 11-Aug-2022 11:16:15 AM
4952 Test 5 Eve 11-Aug-2022 11:13:26 AM
4951 Test 4 Eve 11-Aug-2022 10:52:14 AM
4950 Test 3 Eve 11-Aug-2022 10:49:01 AM
4949 Test 2 Eve 11-Aug-2022 10:46:31 AM
4948 Test 1 Eve 11-Aug-2022 10:42:24 AM
4947 asdf 11-Aug-2022 10:41:10 AM
4946 asdf 11-Aug-2022 10:40:56 AM
4945 asdf 11-Aug-2022 10:40:44 AM
4944 asdf 11-Aug-2022 10:40:31 AM
4943 Test 12 M EL 10-Aug-2022 11:59:43 AM
4942 Test 11 M EL 10-Aug-2022 11:59:08 AM
4941 Test 8 M ELV 10-Aug-2022 11:58:39 AM
4940 Test 5 M ELV 10-Aug-2022 11:58:08 AM
4939 Test 4 M ELV 10-Aug-2022 11:57:42 AM
4938 Test 3 M ELV 10-Aug-2022 11:57:14 AM
4937 Test 2 M ELV 10-Aug-2022 11:56:44 AM
4936 Test 1 M ELV 10-Aug-2022 11:56:15 AM
4935 asdf 10-Aug-2022 11:54:58 AM
4934 asdf 10-Aug-2022 11:54:50 AM
4933 asdf 10-Aug-2022 11:54:43 AM
4932 asdf 10-Aug-2022 11:54:34 AM
4931 asdf 10-Aug-2022 11:54:27 AM
4930 asdf 10-Aug-2022 11:54:17 AM
4929 asdf 10-Aug-2022 11:54:04 AM
4928 Just GIRLS 10-Aug-2022 09:49:20 AM

1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 [Next] [Last]
 
web counter
web counter


To report any error messages or bugs, or other issues, please send email at: info@pakproject.com