You are not logged in.
Dear visitor, welcome to Aqua Computer Forum. If this is your first visit here, please read the Help. It explains how this page works. You must be registered before you can use all the page's features. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.
TrOuble
God





) aber er gibt|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 |
<?
echo "<div align=\"center\">\n";
?>
<?
include "cfg/mySQL_conf.php";
error_reporting(E_ALL);
@mysql_connect(MYSQL_HOST, MYSQL_USER, MYSQL_PASS) OR
die("Keine Verbindung zur Datenbank. Fehlermeldung:".mysql_error());
mysql_select_db(MYSQL_DATABASE) OR
die("Konnte Datenbank nicht benutzen, Fehlermeldung: ".mysql_error());
$sql = "SELECT
vorname,
nachname,
email,
jahrgang,
option1,
option2,
strasse,
plz,
ort
FROM
ehemalige
WHERE
$_POST[select] LIKE '%$_POST[suche]%'
ORDER by vorname ASC";
$suche = mysql_query($sql) OR die(mysql_error());
echo "<table width=\"460\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">\n";
echo " <tr>\n";
echo " <td colspan=\"2\"><div align=\"center\"><strong>".mysql_num_rows($suche)."</strong> Übereinstimmung(en) gefunden!</div></td>\n";
echo " </tr>\n";
echo "</table>\n";
while($suche = mysql_fetch_assoc($suche)) {
echo "<br>\n";
echo "<table width=\"460\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">\n";
echo " <tr>\n";
echo " <td width=\"230\">Vorname</td>\n";
echo " <td width=\"230\">".$suche['vorname']."</td>\n";
echo " </tr>\n";
echo " <tr>\n";
echo " <td>Nachname</td>\n";
echo " <td>".$suche['nachname']."</td>\n";
echo " </tr>\n";
echo " <tr>\n";
echo " <td>Abi-Jahrgang</td>\n";
echo " <td>".$suche['jahrgang']."</td>\n";
echo " </tr>\n";
echo " <tr>\n";
echo " <td colspan=\"2\"></td>\n";
echo " </tr>\n";
echo " <tr>\n";
echo " <td colspan=\"2\"></td>\n";
echo " </tr>\n";
echo " <tr>\n";
echo " <td colspan=\"2\"></td>\n";
echo " </tr>\n";
echo " <tr>\n";
echo " <td colspan=\"2\"><div align=\"center\"><br>\n";
echo " </div></td>\n";
echo " </tr>\n";
echo "</table>\n";
if($suche['option1'] == "Ja") {
echo "<table width=\"460\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">\n";
echo " <tr>\n";
echo " <td>Straße</td>\n";
echo " <td>".$suche['strasse']."</td>\n";
echo " </tr>\n";
echo " <tr>\n";
echo " <td>Postleitzahl</td>\n";
echo " <td>".$suche['plz']."</td>\n";
echo " </tr>\n";
echo " <tr>\n";
echo " <td>Ort</td>\n";
echo " <td>".$suche['ort']."</td>\n";
echo " </tr>\n";
echo " <tr>\n";
echo " <td colspan=\"2\"><div align=\"center\"> </div></td>\n";
echo " </tr>\n";
echo "</table>\n";
}
else {
echo "<div align\=center\">Addresse wird auf Wunsch des Benutzers nicht angezeigt</div>\n";
}
if($suche['option2'] == "Ja") {
echo "<div align\=center\"><a href=\"mailto:".$suche['email']."\">Dem Benutzer eine Email schicken.</a></div>\n";
}
else {
echo "<div align\=center\">Email wird auf Wunsch des Benutzers nicht angezeigt</div>\n";
}
}
?>
<?
echo "</div>\n";
?>
|
TrOuble
God





|
|
Source code |
1 |
while($suche = mysql_fetch_assoc($suche)) {
|
|
|
Source code |
1 |
while($ergebnis = mysql_fetch_assoc($suche)) {
|
|
|
Source code |
1 |
$ergebnis['...'] |
TrOuble
God





Quoted from "Y0Gi"
das kommt davon, wenn man sich auf die bekloppten php-funktionen verlässt und keine wrapperklasse hat. ich werde mich mal daran machen, meine zu veröffentlichen. dann ists in zukunft auch einfacher, code-beispiele zu bringen![]()

-