Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- if (isset($_POST['checked_v']) && $_POST['checked_w']) {
- $foo = array();
- $foo = array_merge($_POST['checked_v'], $_POST['checked_w']);
- $id_list = join(",",$foo );
- $id_list2 = mysql_real_escape_string($id_list);
- $ergebnis = mysql_query("SELECT * FROM asonators WHERE id IN ($id_list2)") or die(mysql_error());
- } elseif (!isset($_POST['checked_w']) && (isset($_POST['checked_v']))) {
- $foo = array();
- $foo = $_POST['checked_v'];
- $id_list = join(",",$foo );
- $id_list2 = mysql_real_escape_string($id_list);
- $ergebnis = mysql_query("SELECT * FROM asonators WHERE id IN ($id_list2)") or die(mysql_error());
- } elseif (!isset($_POST['checked_v']) && (isset($_POST['checked_w']))) {
- $foo = array();
- $foo = $_POST['checked_w'];
- $id_list = join(",",$foo );
- $id_list2 = mysql_real_escape_string($id_list);
- $ergebnis = mysql_query("SELECT * FROM asonators WHERE id IN ($id_list2)") or die(mysql_error());
- } elseif (!isset($_POST['checked_v']) && (!isset($_POST['checked_w']))) {
- $ergebnis = mysql_query("SELECT * FROM asonators");
- }
- while($row = mysql_fetch_object($ergebnis))
- {
- switch($row->type)
- {
- case "E100":
- $aso_type = "E100.gif";
- break;
- case "100":
- $aso_type = "100.gif";
- break;
- case "600":
- $aso_type = "600_102_70.gif";
- break;
- default:
- $aso_type = "nopic.gif";
- }
- echo "<br>";
- echo "<table>";
- echo "<td>";
- echo "<b>Type: ";
- echo $row->name;
- echo "</td>";
- echo "<td></b> <img src='gfx/$aso_type' width='50%' alt='$aso_type'><td>";
- echo "<tr>";
- echo "<td>ID: </td>";
- echo "<td>",$row->id,"</td>";
- echo "<tr>";
- echo "<td><b>Typenreihe: </b></td>";
- echo "<td><b>",$row->type,"</b></td>";
- echo "<tr>";
- echo "<td>min. Belastung F1: </td>";
- echo "<td>",$row->minimum_load," N</td>";
- echo "<tr>";
- echo "<td>max. Belastung F2: </td>";
- echo "<td>",$row->maximum_load," N</td>";
- echo "<tr>";
- echo "<td>Hoehe bei F1: </td>";
- echo "<td>",$row->height_minimum_load," mm</td>";
- echo "<tr>";
- echo "<td>Hoehe bei F2: </td>";
- echo "<td>",$row->height_maximum_load," mm</td>";
- echo "<tr>";
- echo "<td>Hoehe unbelastet: </td>";
- echo "<td>",$row->hight_without_load," mm</td>";
- echo "<tr>";
- echo "<td>Federrate: </td>";
- echo "<td>",$row->springrate," N/mm</td>";
- echo "<tr>";
- echo "<td>Gewicht: </td>";
- echo "<td>",$row->weight," kg</td>";
- echo "<tr>";
- echo "<td>Preis (Brutto): </td>";
- $price = $row->price*1.2;
- echo "<td>$price Euro</td>";
- echo "<tr>";
- echo "</table>";
- echo "<br/>";
- }
- ?>
Add Comment
Please, Sign In to add comment