
PK 
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Printable Form Data</title>
<style>
body {
font-family: Arial, sans-serif;
}
.container {
max-width: 1000px;
margin: 20px auto;
padding: 20px;
border: 1px solid #ccc;
border-radius: 8px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}
p {
margin: 0;
}
strong {
margin-right: 10px;
}
img {
max-width: 100%;
height: auto;
margin-bottom: 10px;
}
</style>
</head>
<body>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Printable Form Data</title>
<style>
/* Your CSS styles here */
</style>
</head>
<body>
<div class="container">
<h2>Customer Details</h2>
<?php
// Check if the form is submitted
echo "<p><strong>Customer Name:</strong> " . htmlspecialchars($_POST["customerName"]) . "</p>";
echo "<p><strong>Phone:</strong> " . htmlspecialchars($_POST["phone"]) . "</p>";
echo "<p><strong>Address:</strong> " . htmlspecialchars($_POST["address"]) . "</p>";
echo "<p><strong>GST:</strong> " . htmlspecialchars($_POST["gst"]) . "</p>";
// Display room details
if (isset($_POST['roomSqft'])) {
$roomSqft = $_POST['roomSqft'];
$roomName = $_POST['roomName'];
$roomCount = count($roomSqft);
$RunSqft = $_POST['RunSqft'];
$customTilePrices = $_POST['customTilePrice'];
$customSkirtingPrices = $_POST['customSkirtingPrice'];
for ($i = 0; $i < $roomCount; $i++) {
echo "<hr>";
echo "<h3>Room Details"," : ". htmlspecialchars($roomName[$i]) . "</h3>";
echo "<p><strong>Tiles Image:</strong> " . htmlspecialchars($_FILES["tilesImage"]["name"][$i]) . "</p>";
//main taile
echo "<p><strong>Square Feet Needed:</strong> " . htmlspecialchars($roomSqft[$i]) . "</p>";
//running tiles
echo "<p><strong>Tiles Image:</strong> " . htmlspecialchars($_FILES["runtilesImage"]["name"][$i]) . "</p>";
echo "<p><strong>skirting tiles Sqft:</strong> " . htmlspecialchars($RunSqft[$i]) . "</p>";
echo "<hr>";
echo "<p><strong>Tiles you needed:</strong> " . ($roomSqft[$i] * 1.5) . "</p>";
echo "<p><strong>skirting tiles you needed:</strong> " . ($RunSqft[$i] * 1.3) . "</p>";
echo "<p><strong>Custom Tile Price:</strong>" . htmlspecialchars($customTilePrices[$i]) . "</p>";
echo "<p><strong>Custom Skirting Tile Price:</strong>" . htmlspecialchars($customSkirtingPrices[$i]) . "</p>";
}
}
?>
<script>
// Use JavaScript to trigger the print dialog
window.onload = function() {
window.print();
};
</script>
</div>
</body>
</html>


PK 99