Hallo, ichhabe folgendes Script und möchte nach der deutschen Bezeichnung alphabetisch sortieren. Kann da jemand helfen? Ich habe leider gar keine Ahnung davon. Danke euch allen
	
							
						
					PHP-Code:
	
	
<?php
require_once("db-conf.php");
$show="";
if(isset($_GET['show'])){
  $show=$_GET['show'];
}
function show_menu(){
  global $db;
  $result=mysql_query("SELECT kategorie FROM links GROUP BY kategorie ORDER BY kategorie", $db);
  print "<ul>";
  while ($record = mysql_fetch_object($result)) {
    $result2=mysql_query("SELECT deutsch FROM translation WHERE englisch='".$record->kategorie."'");
    if($result2 && mysql_num_rows($result2)>0)
      $deutsch=mysql_result($result2, 0);
    if($deutsch=="")
      $deutsch=str_replace("_", " ", $record->kategorie);
    print "<li style='list-style-type:none;' ><a href='index.php?show=".$record->kategorie."'>".$deutsch."</a></li>";
  }
  print "</ul>";
}
function show_list(){
  global $show;
  if($show!=""){
    $result=mysql_query("SELECT link FROM links WHERE kategorie='".$show."'");
    $counter=0;
    $spalte=0;
    print "<table>";
    while ($record = mysql_fetch_object($result)) {
      $counter++;
      $spalte++;
      if($spalte==1)
        print "<tr>";
      print "<td><a href='".$record->link."' target='_new'>".$counter."</a></td>";
      if($spalte>19){
        $spalte=0;
        print "</tr>";
      }
    }
   
    print "</table>";
  }
}
?>
          
 Moderatorin

Kommentar