\n"; print "\n"; /* Start of song listing */ $dir = "./"; if ($dh = opendir( $dir )) { while (( $file = readdir($dh) ) !== false) { $extension = array_pop( explode(".", $file) ); if( $extension == "h2song" ) { print "\t\n"; $content = file( $dir.$file ); $xml = join( " ",$content ); print "\t\t" . getTag( $xml , "" ) . "\n"; print "\t\t" . $url.$file ."\n"; print "\t\t" . getTag( $xml , "" ) . "\n"; print "\t\t" . getTag( $xml , "" ) . "\n"; print "\t\n"; } } closedir( $dh ); } /* End of song listing */ /* Start of pattern listing */ $dir = "./"; if ($dh = opendir( $dir )) { while ( ( $file = readdir( $dh ) ) !== false ) { $extension = array_pop(explode( ".", $file )); if( $extension == "h2pattern" ) { $content = file( $dir.$file ); $xml = join( " " , $content ); print "\t\n"; print "\t\t" . getTag( $xml , "" ) . "\n"; print "\t\t" . $url.$file ."\n"; print "\t\n"; } } closedir( $dh ); } /* End of pattern listing */ /* Start of drumkit listing */ $dir = "./"; if ($dh = opendir( $dir ) ) { while ( ( $file = readdir( $dh ) ) !== false) { $extension = array_pop( explode( ".", $file ) ); if( $extension == "h2drumkit" ) { $content = file( $dir.$file ); $xml = join( " " , $content ); print "\t\n"; //name: filename without extension $name = basename( $file,".h2drumkit" ); If( ISSET( $drumkit_list[ $name ]) ){ $author = $drumkit_list[ $name ][ "author" ]; $info = $drumkit_list[ $name ][ "info" ]; } print "\t\t $name \n"; print "\t\t" . $url.$file ."\n"; print "\t\t$author\n"; print "\t\t$info\n"; print "\t\n"; } } closedir( $dh ); } /* End of pattern listing */ print "\n"; ?>