From 869e3721d75e9798a706d24d93170f44e5ab6cb3 Mon Sep 17 00:00:00 2001 From: Eric Barnes Date: Sun, 11 Sep 2011 14:00:26 -0400 Subject: Changed the add_package_path documentation to show the second param for view path loading. --- user_guide/libraries/loader.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'user_guide/libraries/loader.html') diff --git a/user_guide/libraries/loader.html b/user_guide/libraries/loader.html index af27176ad..98864a700 100644 --- a/user_guide/libraries/loader.html +++ b/user_guide/libraries/loader.html @@ -241,9 +241,9 @@ $this->load->library('foo_bar');

In this instance, it is possible for view naming collisions within packages to occur, and possibly the incorrect package being loaded. To ensure against this, set an optional second parameter of FALSE when calling add_package_path().

-$this->load->add_package_path(APPPATH.'my_app', TRUE);
+$this->load->add_package_path(APPPATH.'my_app', FALSE);
$this->load->view('my_app_index'); // Loads
-$this->load->view('welcome_message'); // Will not load the default welcome_message b/c the second param to add_package_path is TRUE
+$this->load->view('welcome_message'); // Will not load the default welcome_message b/c the second param to add_package_path is FALSE

// Reset things
$this->load->remove_package_path(APPPATH.'my_app');
-- cgit v1.2.3-24-g4f1b