Autocomplete in Eclipse PDT for Codeigniter 2.0.0.
Earlier this month EllisLab, Inc. Released for general consumption Codeigniter 2.0.0. So... I am releasing a NEW screen cast on how to get auto-complete working in Eclipse PDT with the new version. Especially since it is different from the last way I did it. This works in BOTH controllers and Models. This unfortunately does not automatically include CUSTOM libraries, controllers, or models... but it does take care of all the CORE classes built into Codeigniter.
To get this to work, we need to create "base" that will be used to draw from in Eclipse. Then we will add that base to the project "path" so that it can build all the autocomplete data. Please understand the "base" is not required in the "path" for your project to work, it only helps eclipse figure out how to build the autocomplete data. You should never include the "base" in a live website.
/** * @var CI_Config */ var $config; /** * @var CI_DB_active_record */ var $db; /** * @var CI_Email */ var $email; /** * @var CI_Form_validation */ var $form_validation; /** * @var CI_Input */ var $input; /** * @var CI_Loader */ var $load; /** * @var CI_Router */ var $router; /** * @var CI_Session */ var $session; /** * @var CI_Table */ var $table; /** * @var CI_Unit_test */ var $unit; /** * @var CI_URI */ var $uri; /** * @var CI_Pagination */ var $pagination;
You want to place this section of code in 2 files.
You need to make sure that the pasted code is INSIDE the class declaration AND not in a function. This code was originally taken from abisofts blog, but I have had to apply it differently to make it work in the new version of Codeigniter.
The Screen cast:
I recommend viewing this in HD if you have the bandwidth.
- Tags: Autocomplete, Eclipse, PDT, Codeigniter 2.0.0, PHP
- Description: A screen cast and instructions on how to get autocomplete working in Eclipse PDT for Codeigniter 2.0.0.