[Solved] filenames to mysql database [closed]


Use PHP glob() function to get all files from a folder

$files = glob(directory_path."/*"); // get all files in a folder

// Loop through array of fetched files and insert into database.

foreach ($files as $file) {
    $filename = basename($file);

    // WRITE YOU MySQL code here that inserts filenames into DB

}

MySQL Insert

0

solved filenames to mysql database [closed]