The best practice would be to leave the resource calls in View, as it is the one they will serve.
Just as @leonardopessoa commented in your question, you can create templates that provide common parts to the main template, for example:
application / views / header.php
<!DOCTYPE html>
<html>
<head>
<title>Hello World - Template</title>
<link rel="stylesheet" href="folha_de_estilo_main_para_todos.css">
</head>
<body>
applications / views / footer.php
<script src="script_main_para_todos.js"></script>
</body>
</html>
applications / views / page_personal.php
<p>
Hello world - Template do método personal!
</p>
applications / views / page_contact.php
<p>
Hello again, world - Template do método contact!
</p>
<script src="script_customizado_apenas_para_este_template.js"></script>
applications / controllers / pages.php
class Pages extends CI_Controller {
public function index()
{
$this->load->view('header');
$this->load->view('page_personal');
$this->load->view('footer');
}
}
public function contact()
{
$this->load->view('header');
$this->load->view('page_contact');
$this->load->view('footer');
}
}
Well, I do not think there is an ideal way, but in my opinion, this would be the best way to organize the resources in an MVC application, especially applications with CodeIgniter, which does not provide such cool legal helpers to do this.
I used code snippets from the following link to write this answer, in it, you could find another way to implement templates in CI, but I did not find anything interesting: link