Frontpage Drop-Down-Feld füllen mit Select aus MySQL mit php ..

Frontpage Drop-Down-Feld füllen mit Select aus MySQL mit php ..

Post by Volker Er » Sun, 10 Dec 2000 19:04:54



Hallo!

Ich habe eine Frontpage-Dropdown-Liste und wollte diese mit vorhandenen
Werten aus eine Mysql-DB fllen. Weiss jmd. wie das geht. Ansonsten msste
ich alle Werte in HTML-Text definieren.

Gruss und Dank!
Volker

begin 666 Volker Erb.vcf
M0D5'24XZ5D-!4D0-"E9%4E-)3TXZ,BXQ#0I..D5R8CM6;VQK97([.T1I<&PN

M3#M)3E1%4DY%5#I6;VQK97)?17)B0'0M;VYL:6YE+F1E#0I%34%)3#M04D5&
M.TE.5$523D54.E8N17)B0'0M;VYL:6YE+F1E#0I%34%)3#M)3E1%4DY%5#I+
M+E8N17)B0'0M;VYL:6YE+F1E#0I%34%)3#M)3E1%4DY%5#IK=F5T=65 >6%H
M;V\N9&4-"D5-04E,.TE.5$523D54.G9O;&ME<BYE<F) =V5B+F1E#0I2158Z

`
end

 
 
 

Frontpage Drop-Down-Feld füllen mit Select aus MySQL mit php ..

Post by Knut Harmse » Fri, 15 Dec 2000 23:52:06


Versuchs damit:

 file://Verbindung zum Server erstellen

// DB Abfrage Kategorien ausw?hlen

$Result = mysql_db_query("DB", "SELECT Kategorie FROM tabelle GROUP BY
Kategorie");
 // Fehlerbehandlung
 if (!$Result) {
 echo "Die Abfrage ist nicht m?glich";
 exit;
 }

// Ausgabe der Kategorien in Popup-Menu

echo "<form action='foo.php' method='get'>";
echo "<select name='kategorie'>";
echo "<option Value=''>W?hlen Sie eine Kategorie</option>";
while ($row = mysql_fetch_array($Result)) {
 $arr=$row;
 foreach ($arr as $elem) {

Quote:}

 echo "<option value='$elem'>$elem\n";
Quote:}

echo "</select>";
echo "<input type=submit value='OK'>";
echo "</form>";

Gruss



Quote:> Hallo!

> Ich habe eine Frontpage-Dropdown-Liste und wollte diese mit vorhandenen
> Werten aus eine Mysql-DB fllen. Weiss jmd. wie das geht. Ansonsten msste
> ich alle Werte in HTML-Text definieren.

> Gruss und Dank!
> Volker


 
 
 

1. Netscape can't handle drop-down select boxes

Greetings,

I run RH 6.2 and Netscape Navigator 4.73.  I've also run most of the
recent previous versions of Netscape and they all seem to have the same
extremely annoying problem... they can't handle drop-down select boxes
with a lot of selections.

Seems every time I encounter one of these drop-down boxes on a form, after
I make my selection, all ability to use the keyboard is gone.  I mean I
can't complete any more form elements, can't even change the dang url on
the address line until I close and re-start netscape.  Does anyone have a
clue about this?

--- rant mode on ----

Since Netscape is virtually the only choice for a browser in Linux, I've
pretty much stopped using Linux because of this.  I was thinking of Lynx,
but it doesn't seem to do tables.  How the hell can Linux ever succeed
without a friggin decent browser?

--- rant mode off ----

--

Elden Fenison
http://www.moondog.org

2. Streaming Audio Server - howto?

3. PHP/MySQL "mysql.sock" not found ???

4. Visual BS++

5. weird php error when using php-mysql-4.2.3 from ports

6. games: DOOM can't install

7. PHP + MySQL - apparently installed OK - but no MySQL support!

8. Using Linux as a fileserver?

9. PHP+MySQL vs. PHP+PostgreSQL

10. My DOS fell down and can't get up....

11. Tim O'Reily fell down and hit his head.

12. My ext2 filesystem fell down and Linux can't get up!

13. SAMBA mit vielen FILES