This page is for importing your events from a comma seperated file (CSV) directly into the the events database. The limitation of this upload is that it does not support the extra questions, only the core event configuration.
One final note, you will see that the header row, fist column has a 0 while other rows have a 1. This tells the upload to ignore rows that have the 0 identifier and only use rows with the 1.
This is the first pass at the uploader, but for those of you who have alot of events, particularly events that are similar in setup, this will be a time saver.
Upload files:
"; for ($x = 0; $x < $num_of_uploads; $x++) { $form .= "*"; } $form .= "
*Maximum file name length (minus extension) is 15 characters. Anything over that will be cut to only 15 characters. Valid file type(s): "; for ($x = 0; $x < count($file_types_array); $x++) { if ($x < count($file_types_array) - 1) { $form .= $file_types_array[$x] . ", "; } else { $form .= $file_types_array[$x] . ".
"; } } $form .= ""; echo($form); } else { foreach ($_FILES["file"]["error"] as $key => $value) { if ($_FILES["file"]["name"][$key] != "") { if ($value == UPLOAD_ERR_OK) { $origfilename = $_FILES["file"]["name"][$key]; $filename = explode(".", $_FILES["file"]["name"][$key]); $filenameext = $filename[count($filename) - 1]; unset($filename[count($filename) - 1]); $filename = implode(".", $filename); $filename = substr($filename, 0, 15) . "." . $filenameext; $file_ext_allow = FALSE; for ($x = 0; $x < count($file_types_array); $x++) { if ($filenameext == $file_types_array[$x]) { $file_ext_allow = TRUE; } } if ($file_ext_allow) { if ($_FILES["file"]["size"][$key] < $max_file_size) { if (move_uploaded_file($_FILES["file"]["tmp_name"][$key], $upload_dir . $filename)) { echo("File uploaded successfully. - " . $filename . "
"); } else { echo($origfilename . " was not successfully uploaded