Wrote my code to work with a specific .cvs format and it was working for the format of the files I had. Now the format of the .cvs file has changed.
So now it looks like everything is inserting but it has shifted over. More specifically everything has moved over one whole column to the right.
I was able to modify the code to make it move further over to the right, but I was unsuccessful at moving it to the left.
Here the part of my code that is having issues:
if($deleteSuccess == 1){
echo "Now inserting all new records";
$handle = fopen($target_file, "r");
$count = 0;
while (($data = fgetcsv($handle, 0, ",")) !== FALSE) {
$name = $data[0];
$correct0 = str_replace("'", "", $name);
$correct1 = str_replace("'", "", $data[1]);
$correct2 = str_replace("'", "", $data[2]);
$correct3 = str_replace("'", "", $data[3]);
$correct4 = str_replace("'", "", $data[4]);
$correct5 = str_replace("'", "", $data[5]);
$correct6 = str_replace("'", "", $data[6]);
$correct7 = str_replace("'", "", $data[7]);
$import="INSERT into DVDCatalog.testtable(`Volume Name`,`DVD Number`,`Type`,`Category`,`Date`,`Author`,`Availablity`,`Picture`) values('$name','$correct1','$correct2','$correct3','$correct4','$correct5','$correct6','$correct7')";
$count = $count + 1;
mysqli_query($conn, $import);
if(mysqli_error($conn)){
echo "<br> Problem with --> ".$import."<br>";
Thanks.