Upload CSV and Insert Data into Mysql Using PHP

preview_player
Показать описание
Рекомендации по теме
Комментарии
Автор

Thank you !

For those who have the error "Notice: Undefined offset: 1", you can replace the line of code "while($data = fgetcsv($handle))" with this one "while($data = fgetcsv($handle, 1000, ";"))". You must specify the separator.

Sami-sgos
Автор

apart from the computer talk..this really helped me upload a lot of data to the mysql data base.

Thanks for the code...

Kobi

kobimontague
Автор

Awesome Tutorial. Thanks Webslesson!!!

agehjeremiah
Автор

Thank you so much. You're so resourceful.

orpee
Автор

Apart from saying "friends" 1Milloin times

That wae very helpful ...


Friend 😁♥

fwurjyz
Автор

Wow. this is awesome. I never wanted to use third parties library and here is pure php system.

mutalemulenga
Автор

Hello sir, thanks for code. Sir, i have two queries. When i upload CSV file using this code, CSV heading at the top of csv are also upload in database. Tell me which condition is used for this and also tell me how i validate csv in uploded time using php that data should not repeated again.

ekanshbihal
Автор

very nice clear and precise thanks a ton

--INDIAN--TRADER
Автор

it doesn't work for me. Nothing happens.
very frustrating because I did everything what you did and it doesn't work for me.

danielchung
Автор

Thanks is very useful, but is there any way that I can convert excel file to csv in php without using plagins

hyasinti
Автор

It is getting inserted but not with actual value... help me out with this

umabm
Автор

Is this will be work on live server ??

AhmedAli-kyjt
Автор

This is fantastic and helpful
How we can add the data by escaping the first row

niceboyyou
Автор

if entry exit then wont be uplaod again ? how to put code in this section and which code?

samikhaneth
Автор

Great one.made my life easier... :D (Y)

shovonrahmanshuvo
Автор

csv file add images how can get that image save folded and database add in php

parthpd
Автор

The line :
($_FILES['file']['name'])
Is giving an error as : Undefined index: file
How to solve this issue?

dhruvchauhan
Автор

Good day sir.
Is this compatible for php 5?
Or 7 only?

Thanks.

robertbobila
Автор

can i do that with file type is xlsx ?

gz
Автор

i get this notice but i can"t solve the problem

Notice: Undefined offset: 1 in on line 14

help me to figure it out
thanks

ariefunited
join shbcf.ru