#21 React JS Tutorial with Laravel | Dynamically Manage App Static Pages (III) | Display CMS Pages

preview_player
Показать описание
Complete React JS Playlist from the Beginning:

In Part-21, we will continue working on the CMS Pages module. In this video, we will display CMS Pages at frontend dynamically that we created last time in the admin panel like About Us, Terms & Conditions, Privacy Policy etc.

1) Create Controller:-
First of all, we create CmsController for the front end so we will create under path \app\Http\Controllers\Front\
php artisan make:controller Front/CmsController

2) Create Route:-

3) Include Model :-
use App\Models\CmsPage;

4) Create cmsPage function :-

Now we can update links of Cms Pages located at footer like we can add About Us Page link and also we can create other CMS Pages like Company Information and give its link as well.

We will send the user to 404 page if CMS Page is disabled or does not exists at all.

Now we are going to work on CMS Pages API so that we can show these CMS Pages in React App as well.

Popular Stack Developers Series that can help you:-

►Join this channel to get the complete source code of all series:

Follow Stack Developers on Social Media to get updates and resolve your queries

#reactjs #reactjscourse #reactjsforbeginners
Рекомендации по теме