Тёмный

Upload Excel in MySQL using Phpspreadsheet in CodeIgniter 

Knowledge Thrusters
Подписаться 3,6 тыс.
Просмотров 14 тыс.
50% 1

In this video , you will be able to upload excel using phpspreadsheet in CodeIgniter.
Steps:
Create a form and input type file
In your controller, get file and check for extension
pathinfo - get the file extension (PATHINFO_EXTENSION)
For csv - $reader= new \PhpOffice\PhpSpreadsheet\Reader\Csv();
For xls - $reader= new \PhpOffice\PhpSpreadsheet\Reader\Xls();
For xlsx - $reader= new \PhpOffice\PhpSpreadsheet\Reader\Xlsx();
For loading the file use reader load function
getActiveSheet - for getting the active worksheet of excel
toArray - fetch the sheet data into array
create an array for inserting into database
insert_batch - for inserting batch data into database
Install php spreadsheet in codeigniter, if you have not watched it please check it out:
• Installation of PhpSpr...
Create excel
• Create Excel Using PHP...
Documentation:
phpspreadsheet.readthedocs.io...
Starting hello world:
phpspreadsheet.readthedocs.io...
Code Link:
github.com/sushma-singh-yadav...
Upload Excel in MySQL using Phpspreadsheet in CodeIgniter
#codeigniter #knowledgethrusters

Опубликовано:

 

14 май 2021

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 29   
@narheben
@narheben 3 года назад
You help me so much, I really love this. I suffered from several libraries but you just saved me. Thanks again
@Aflover1st
@Aflover1st 2 года назад
Thank you so much for your tutorial, it really helps me!
@SunilKumar-lf2nd
@SunilKumar-lf2nd 5 месяцев назад
Gracias
@ainunnafil6331
@ainunnafil6331 2 года назад
thank you so much for this video!
@ibrahimkhan7867
@ibrahimkhan7867 3 года назад
Very very useful video thank you for so much for sharing an amazing video
@bangretz6450
@bangretz6450 2 года назад
thank you so much for video!
@mert7349
@mert7349 2 года назад
Very very very very useful video thank you for so much 💗
@vivekjalankar6647
@vivekjalankar6647 2 года назад
Thank you so much for tutorial finally my bug solved
@belajarcoding6657
@belajarcoding6657 Год назад
thank you, your really help me
@rizkyfadillah3928
@rizkyfadillah3928 Год назад
truly helpfull, thanks
@ekamelndsr
@ekamelndsr Год назад
thank you so muchhh
@aymenlejmi1087
@aymenlejmi1087 7 месяцев назад
thank you for the video, in fact i want to apply some security check in my columns, how can i proceed ?
@ashishnath9121
@ashishnath9121 2 года назад
Can you please tell me how to upload xlsx file as json in mysql with the help of phpspreadsheet in core php. I am not familiar with codeignitor🙏🙏🙏🙏
@BSVCREATION45
@BSVCREATION45 2 года назад
Hello mam i am using phpexcel library not phpspreadsheet bu i am faceing issue in reading my file can you please help me
@NoniGopalChandro
@NoniGopalChandro 10 месяцев назад
where is the "PhpSpreadsheet"? i don't found "PhpSpreadsheet" into your source code. can you please let me know where i have to upload "PhpSpreadsheet"? thanks.
@anandgupta8375
@anandgupta8375 3 года назад
how to import excel file with images into database ??
@PratikBhuva
@PratikBhuva 2 года назад
I tried the step metioned in your tutorial and works fine on localhost but when uploaded on webserver it doesn't work. why? anyidea?
@jeffpena3986
@jeffpena3986 2 года назад
Same, I tried it to a centos server and $_Post was empty. Did you able to fixed it?
@proxygulshan
@proxygulshan 3 года назад
getting error , Severity: Notice Message: Trying to access array offset on value of type int Filename: Cell/DefaultValueBinder.php Line Number: 56
@tanwiralam1813
@tanwiralam1813 2 года назад
how to filter duplicate data..?
@pradeepkushwaha788
@pradeepkushwaha788 3 года назад
Please cashfree payment gateway intigration in laravel i m useing api but token issue please make a vedio..
@reynaldiarytumanan1199
@reynaldiarytumanan1199 2 года назад
my problem is :The requested URL was not found on this server. when i click submit after choose file. please help me
@knowledgethrusters
@knowledgethrusters 2 года назад
@Reynaldi Please Check that you have defined route properly and that same function is present in your controller.
@reynaldiarytumanan1199
@reynaldiarytumanan1199 2 года назад
@@knowledgethrusters thank u, my problem is fixed, but my new problem is I don't know how to import data that has been connected to the database in the form of an integer, for example i have field id_B in table A related id_B in table B. I want to import data to table A, how to make usb data in the form of integers can be read and imported to the database, where the id_B data in excel is in the form of varchar? thank you in advance 🙌
@knowledgethrusters
@knowledgethrusters 2 года назад
@Reynaldi Ary Tumanan Please try this if you want to convert to integar $int = (int)$num;
@reynaldiarytumanan1199
@reynaldiarytumanan1199 2 года назад
@@knowledgethrusters oh yeah, i will try it
@reynaldiarytumanan1199
@reynaldiarytumanan1199 2 года назад
@@knowledgethrusters i'm sorry, i don't know how to code this
@user-si8lr4wp3c
@user-si8lr4wp3c 3 года назад
girl will be girl. she's excel sheet has such stuff that always shuffling in their mind. LOL😃😃
@abdallahhussein5997
@abdallahhussein5997 2 года назад
How to 1.protect worksheets and restrict user actions like row and column insertion, deletion, and resizing using php spreadsheet 2.Protect cells using a lock cell feature to restrict user editing action in selected cells using php spreadsheet 3.hide formula and set invisible using php spreadsheet
Далее
How to Import CSV Data into Mysql using Codeigniter
20:30
One moment can change your life ✨🔄
00:32
Просмотров 8 млн
Read any Excel File using PHPExcel in PHP
11:44
Просмотров 40 тыс.
How to Import Excel File in Codeigniter
19:28
Просмотров 62 тыс.
Import Excel File Data into MySQL Database using PHP
15:27
Export Data to Excel in Codeigniter using PHPExcel
16:31