[英]Advice for setting up Aptana for CodeIgniter?
I've used Aptana for a good number of web projects and like it a lot. 我已经使用Aptana进行了大量的网络项目并喜欢它。 I've also used CodeIgniter for a couple projects and liked it, as well.
我也将CodeIgniter用于了几个项目并且也喜欢它。 Now I'm hoping to combine the two in a happy marriage of cross-platform productivity.
现在我希望将这两者结合起来,实现跨平台生产力的幸福婚姻。 Any advice on setting up Aptana's more useful features?
有关设置Aptana更实用功能的建议吗? I'm hoping to get any of the following:
我希望得到以下任何一项:
If completely infeasible, what IDE would you suggest? 如果完全不可行,你会建议什么IDE? Generic Aptana PHP setup tips would also be welcome, as they might guide me toward the ideal setup.
Generic Aptana PHP设置技巧也会受到欢迎,因为它们可能会引导我走向理想的设置。
I would install Aptana as an Eclipse plug-in. 我会安装Aptana作为Eclipse插件。 Allows you to latter down the road install GWT or Flex with no fuss.
允许您在后面安装GWT或Flex而不用担心。 Plus, Aptana as a plug-in has worked much better for me.
另外,作为插件的Aptana对我来说效果更好。 Both in terms of stability and of usability.
在稳定性和可用性方面。
I used to have Aptana crash on me every two days and since I'm running Eclipse with Aptana as a plug-in it never again crashed . 我曾经每两天让Aptana崩溃, 因为我用Aptana作为插件运行Eclipse,它再也没有崩溃过 。
Eclipse with Aptana as a plug-in also has some handy features, like spell-checking, that Aptana did not have and has greatly improved my comments. 使用Aptana作为插件的Eclipse也有一些方便的功能,如拼写检查,Aptana没有,并且大大改进了我的评论。 That said, I must agree with you on the great level of detail and attention Aptana team has put in their software.
也就是说,我必须就Aptana团队在他们的软件中提供的高度细节和关注度达成一致。
i have found the solution for this in codeigniter forum. 我在codeigniter论坛找到了解决方案。
http://codeigniter.com/forums/viewthread/187641/ http://codeigniter.com/forums/viewthread/187641/
I came up with a slightly “safer” solution. 我提出了一个稍微“更安全”的解决方案。 rather than modifying the system files, create a folder called “autocomplete” (or whatever name you want)
而不是修改系统文件,创建一个名为“自动完成”的文件夹(或任何你想要的名称)
ie 即
application 应用
autocomplete 自动完成
system 系统
user_guide 用户指南
then create a file (in autocomplete) called controller.php with the code below (class CI_Controller etc) . 然后使用下面的代码(类CI_Controller等)创建一个名为controller.php的文件(在自动完成中)。 then copy this file and with the name model.php and change the class in that file to CI_Model.
然后复制此文件并使用名称model.php并将该文件中的类更改为CI_Model。 Aptana then uses these to remap it's autocompletion.
然后Aptana使用这些来重新映射它的自动完成。 Just add any more functions you want autocompletion for for each file.
只需为每个文件添加您想要自动完成的任何其他功能。 (for instance i added CI_Cart which wasn't in the original example in that link
(例如我添加了CI_Cart,它不在该链接的原始示例中
(Note currently this only gives autocomplete for Models and Controllers. I guess if you're extending other Classes and need autocompletion in those you'll need to make a new file in the autocomplete folder with a list of all the classes that you want that class to see) (注意,目前这只为模型和控制器提供了自动完成功能。我想如果你正在扩展其他类并需要自动完成那些你需要在autocomplete文件夹中创建一个新文件,其中包含你想要的所有类的列表上课看)
class CI_Controller {
/**
* @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;
/**
* @var CI_Cart
*/
var $cart;
}
?>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.