What is view
View folder contains all the markup files header, footer, sidebar, etc. They can be reused by embedding anywhere in the controller. They are the interface design which is displayed on the user's browser and can never be called directly, they have to be loaded in the controller's file.
Create a file and save it in application/views folder. For example, we have created a file Firstview.php,
View can't be accessed directly. It is always loaded in the controller file. The following line is used to load a view page.
Write your view's page name in the bracket. You don't need to specify .php unless you are using some other extension.
Now, go to your controller file (Main.php) and write this code as shown below.
Loading Multiple Views
Your view may contain several files like header, footer, side menu, form, etc. Sometimes you may need to load more than one file simultaneously. In that case, simply call $this->load->view() multiple times.