Bracuhe dringend einfaches script

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Bracuhe dringend einfaches script

    Kann mir bitte jemand behilflich sein,
    ich brauche dringend ein php script das mir dateinamen aus einem ordner ausliest und sie in eine tabelle einträgt.
    Die Dateinamen sind folgendermassen aufgebaut ******-******,
    es soll der Eintrag bis zum "-" in die erste spalte, und der zweite teil (nach dem minus) in eine zweite spalte aufgelistet werden.
    Vielen dank im vorraus....

    php-Entwicklung | ebiz-consult.de
    PHP-Webhosting für PHP Entwickler | ebiz-webhosting.de
    die PHP Marktplatz-Software | ebiz-trader.de

  • #2
    $d = opendir('.');
    while ($fn=readdir($d))
    if (ereg ('^[a-z]+-[a-z]+$', $fn) {
    list ($a,$b) = explode ('-',$fn);
    // und jetzt $a, $b in die DB eintragen
    }
    closedir ($d);

    -=* Titus *=-
    | php pro |
    |nerd for life|
    """""""""""""""

    the PHP resource

    Comment


    • #3


      cool, brauch ich auch!

      Danke

      php-Entwicklung | ebiz-consult.de
      PHP-Webhosting für PHP Entwickler | ebiz-webhosting.de
      die PHP Marktplatz-Software | ebiz-trader.de

      Comment

      Working...
      X