adapt to real environment
git-svn-id: file:///home/www/usr01/svn/gnuviechadmin/gnuviech.info/gnuviechadmin/trunk@33 a67ec6bc-e5d5-0310-a910-815c51eb3124
This commit is contained in:
parent
2641ac4f10
commit
f6ca9aa8a1
5 changed files with 23 additions and 19 deletions
|
@ -30,7 +30,7 @@ function country_selbox($varname, $default=0) {
|
|||
global $dbh;
|
||||
$result=db_query($dbh, "SELECT * FROM country ORDER BY name");
|
||||
printf("<SELECT name=\"%s\">", $varname);
|
||||
while ($row=pg_fetch_array($result)) {
|
||||
while ($row=db_fetch_array($result)) {
|
||||
printf("<OPTION value=\"%d\"%s>%s</OPTION>",
|
||||
$row["id"], ($row["id"]==$default) ? " selected" : "",
|
||||
$row["name"]);
|
||||
|
@ -45,7 +45,7 @@ function client_selbox($varname, $default=0) {
|
|||
"WHERE cl.country=co.id ORDER BY cl.firstname, ".
|
||||
"cl.lastname");
|
||||
printf("<SELECT name=\"%s\">", $varname);
|
||||
while ($row=pg_fetch_array($result)) {
|
||||
while ($row=db_fetch_array($result)) {
|
||||
printf("<OPTION value=\"%d\"%s>%s %s (%s, %s)</OPTION>",
|
||||
$row["id"], ($row["id"]==$default) ? " selected" : "",
|
||||
$row["firstname"], $row["lastname"], $row["town"],
|
||||
|
@ -182,4 +182,4 @@ default: ?>
|
|||
You are trying to trick me. I don't like this
|
||||
<?php endswitch; ?>
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue