phpnewbie
phpnewbie

Reputation:

CodeIgniter with Eclipse PDT, is clean integration possible?

I am attempting to setup codeigniter with eclipse but am getting project errors. From what I understand this should be as simple as creating a new project in eclipse and pointing to the root directory of codeigniter. This properly loads up the codeigniter files but eclipse reports several errors. Looking into the files, it seems like the errors are coming from html files and/or files that print html. For instance, footer.php is showing up as having an error because there is a closing tag but no opening tag. Any suggestions on how to overcome this? At this point would code completion / debugging be too much to ask for as well?

UPDATE: so from what I am gathering from the response below (and searching around on the web) is that when using codeigniter with eclipse one can only take advantage of the code completion / editing features? I also noticed that I am getting NoClassDefFoundError when attempting to open some of the .php files in the eclipse project tree for editing. Surely I must be missing something and there is a way to achieve tighter integration with codeigniter and eclipse? (i would strongly prefer to stick with eclipse as opposed to switching ides) Or maybe this is an issue with my eclipse/pdt setup?

UPDATE 2: I just downloaded the latest eclipse version (galileo) and it seemed to fix all of these issues! except for debugging of course ...

Upvotes: 5

Views: 6511

Answers (4)

Amitabh
Amitabh

Reputation: 739

you can achieve tighter integration by initializing the Ci core classes in CI_Base constructor which will also allow you to get auto complete for core classes check out these links:

Upvotes: 3

Justin Ethier
Justin Ethier

Reputation: 134207

For what it's worth, I have been able to get debugging to work using XDebug and the Netbeans IDE. If you cannot get debugging to work in Eclipse you might give Netbeans a try - if for no other reason, to have the ability to debug should you ever need to step through your application's code...

Upvotes: 0

Virat Kadaru
Virat Kadaru

Reputation: 2256

Try Aptana.

The last time I checked I was able to do a step by step debug on it and did not see any errors in my project. It is also built on eclipse, so there is nothing new to learn.

Upvotes: 0

bumperbox
bumperbox

Reputation: 10214

you will get lots of html errors because the html has been broken into chunks and is not a complete document just ignore them thats what i do (there are settings somewhere that control what errors are validated against in eclipse)

i still use the php/html/js code completion and it works fine even with the errors

if you are using svn version control, add subclipse plugin, so you can do that from within eclipse too

Upvotes: 2

Related Questions