MYHOSPITALNOW.COM

Find Trusted Doctors & Hospitals

Discover healthcare providers, compare hospitals, and explore treatment options worldwide.

Free Treatment Quotes • Doctor Search • Hospital Comparison

Find Healthcare Options

www.myhospitalnow.com

How to add Data to a New Column in Laravel PHP Framework? Part-2

How to add Data to a New Column in Laravel PHP Framework?

In the previous blog part-1, we added a new column(email). Here, we’ll add data to a new column(email).

Click CRUD Functionality of this Table. Click Search with Pagination.

Customer Service Data page with Service Name, Email, Edit and Delete columns and no records

Step 1. Now, Go to app/Service.php file and write down the following code:

Sublime Text showing app/Service.php with email added to the fillable array

Step 2. Go to app/Http/Controller/ServiceController.php file and write down the following code:

Step 3. Now, Go to Resources/views/Service/create.blade.php file and write down the following code:

Sublime Text showing create.blade.php with a new email input field in the form

Step 4. Similarly, Go to Resources/views/Service/edit.blade.php file and write down the following code:

Sublime Text showing edit.blade.php with an email input bound to the service email value

Refresh URL

Laravel Add Data form filled with Central Government and an email address, with Submit and Back buttons
Customer Service Data table listing five services with their email addresses, Edit and Delete buttons

Thanks

Find Trusted Cardiac Hospitals

Compare heart hospitals by city and services — all in one place.

Explore Hospitals
With MotoShare.in, you can book a bike instantly, enjoy doorstep delivery, and ride without worries. Perfect for travelers, professionals, and adventure enthusiasts looking for a seamless mobility solution.

Related Posts

Simple Ajax CRUD Application in Laravel

Step 1 – Create a fresh laravel projet First off all , create a project using following command given below – Change Directory to AjaxCrud folder Step…

Read More

CRUD Operations in Laravel PHP Framework

Step 1 – Download Laravel 5.8 In first step you have to download Laravel 5.8 version. For this you have to go to command prompt, in which…

Read More

How to implement CRUD functions in the Laravel PHP Framework? Part-1

How to implement CRUD functions in the Laravel PHP Framework? Within computer programming, the acronym CRUD stands for create, read, update and delete. Step 1. Create a…

Read More

Todo Application in Laravel

1.Create Project in Laravel Composer create-project laravel/laravel todolist 2.Create CRUD Controller php artisan make:controller TodosController –resource 3.Route setup of CRUD Controller routes/web.php 4.Create Database todolist localhost/phpmyadmin create…

Read More

Python Tutorials: Database operations using python – mysql

This tutorial connects Python to MySQL with the official mysql-connector-python driver and runs the full set of CRUD operations: create a database and table, then insert, read,…

Read More

Elastic Tutorial: Elasticsearch 8.X Installation & CRUD in Linux

Rajesh Kumar I’m Rajesh Kumar, a DevOps, SRE, DevSecOps, Cloud, and Platform Engineering expert passionate about sharing practical knowledge, real-world experiences, and industry best practices. I have…

Read More