0

I'm using the PHP Eclipse. When a XML file is opened, Eclipse doesn't seem to recognize the xml, meaning that all looks black. When opened the XML file like "open with" and point to eclipse, it works fine.

What setting can be set to use that automatically so that eclipse recognizes it all the time?

Same goes for HTML files actually.

3 Answers 3

5

In the eclipse Preferences you can configure which editor opens for a given file type. This setting can be found under Window->Preferences->General->Editors->File Associations.

Sign up to request clarification or add additional context in comments.

Comments

3

you have to install a plugin that can parse xml like xmlbuddy, or the eclipse WTP (Web Tools Platform).

I recommend Eclipse WTP because it comes standard with Eclipse and integrates nicely into the IDE. It's also trivial to install as you can see in this tutorial video: http://mirrors.ibiblio.org/pub/mirrors/eclipse/technology/phoenix/demos/install-wtp/install-wtp.html

success

Comments

2

The last editor you used for a file is remembered, so if you opened a particular XML file prior to installing an XML editor, you'll still end up in the plain Text Editor when you go to open the file again. Open the file with the XML editor once from the Open With context menu, and it should then "stick".

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.