Skip to main content



      Home
Home » Newcomers » Newcomers » content type clash(when two content types share the same file association)
content type clash [message #556131] Mon, 30 August 2010 18:57 Go to next message
Eclipse UserFriend
Hi,

I'm using eclipse 3.5.2, and among other things have a few j2ee plugins and php.
In the content types (under text) both the jsp type and php type both have ".inc" in the file association.

The workspace in which I work with php is a different one than the one I'm using for jsp (or java for that matter) and so in the php workbench I defaulted the php editor to handle .inc files.

When I open a .inc file in the editor though all of the text is one big error (all red underlined) and in the Problems view all of the errors are from type "JSP Problem", also when I view the properties of the file I get Type: File (JSP).

The file associations in content types (in both the php and jsp) are locked so I can't even remove that (not that I think that it's a good idea).

Any ideas of how I can fix this issue?
Thanks.
Re: content type clash [message #556132 is a reply to message #556131] Mon, 30 August 2010 19:08 Go to previous messageGo to next message
Eclipse UserFriend
On 2010.08.30 16:57, thenitmaster@hotmail.com wrote:
> Hi,
>
> I'm using eclipse 3.5.2, and among other things have a few j2ee plugins
> and php.
> In the content types (under text) both the jsp type and php type both
> have ".inc" in the file association.
>
> The workspace in which I work with php is a different one than the one
> I'm using for jsp (or java for that matter) and so in the php workbench
> I defaulted the php editor to handle .inc files.
>
> When I open a .inc file in the editor though all of the text is one big
> error (all red underlined) and in the Problems view all of the errors
> are from type "JSP Problem", also when I view the properties of the file
> I get Type: File (JSP).
>
> The file associations in content types (in both the php and jsp) are
> locked so I can't even remove that (not that I think that it's a good
> idea).
>
> Any ideas of how I can fix this issue?
> Thanks.

Answer and question++:

Have you considered not only separate workspaces, but separate Eclipses?
One PDT and one JEE? I maintain separate ones for JEE, Android and
BlackBerry though not for PHP which I don't do. It saves me a lot of
trouble.

I'd like to know if this is helpful. Anyone with another opinion should
answer too: I'm planning on using PDT very soon, so it's relevant to me
to know whether to attempt it from Eclipse JEE or keep it separate as I
(found I had to) do with my other two Eclipse copies.

Russ Bateman
Re: content type clash [message #556134 is a reply to message #556131] Mon, 30 August 2010 19:42 Go to previous messageGo to next message
Eclipse UserFriend
On Mon, 2010-08-30 at 18:57 -0400, thenitmaster@hotmail.com wrote:
> Hi,
>
> I'm using eclipse 3.5.2, and among other things have a few j2ee plugins and php.
> In the content types (under text) both the jsp type and php type both have ".inc" in the file association.
>
> The workspace in which I work with php is a different one than the one I'm using for jsp (or java for that matter) and so in the php workbench I defaulted the php editor to handle .inc files.
>
> When I open a .inc file in the editor though all of the text is one big error (all red underlined) and in the Problems view all of the errors are from type "JSP Problem", also when I view the properties of the file I get Type: File (JSP).
>
> The file associations in content types (in both the php and jsp) are locked so I can't even remove that (not that I think that it's a good idea).
>
> Any ideas of how I can fix this issue?
> Thanks.

Right click on the file and select Open with... Then select the
appropriate editor for the file you are editing. Eclipse will remember
the last editor used for a given file, so you should only have to do
this the first time you open a file.
Re: content type clash [message #556147 is a reply to message #556131] Tue, 31 August 2010 01:25 Go to previous messageGo to next message
Eclipse UserFriend
David:
The editor which is used to open php files is indeed the php editor, that's not the problem. the problem is that eclipse thinks the inc file is a jsp so when it checks it for errors it uses jsp rules and not php (this is not editor specific since you can see files with errors in the Explor view).
When I right click the file and go to Open With, the php editor is already marked.


Russell:
I thought about having two distinct instances but hoped (still do) that it can be avoided.
Though I can appreciate some of the pros with this solution, having just one IDE to work with, no matter what you're working on still seems optimal.

If there's no choice I'll have to go with the multiple instances option...
Any other option?

Thanks.
Re: content type clash [message #556373 is a reply to message #556131] Wed, 01 September 2010 01:14 Go to previous messageGo to next message
Eclipse UserFriend
On 8/30/2010 6:57 PM, thenitmaster@hotmail.com wrote:
> I'm using eclipse 3.5.2, and among other things have a few j2ee plugins
> and php.
> In the content types (under text) both the jsp type and php type both
> have ".inc" in the file association.

That's really strange, as with just the
eclipse-jee-galileo-SR2-win32.zip, *.inc isn't associated with any
editor or listed under the JSP content types.

--
Nitin Dahyabhai
Eclipse WTP Source Editing and JSDT
IBM Rational
Re: content type clash [message #556375 is a reply to message #556131] Wed, 01 September 2010 01:48 Go to previous messageGo to next message
Eclipse UserFriend
well, maybe it's because i'm using
eclipse 3.5.2 (M20100211-1343) under ubuntu
or
maybe that addition was made by one of the plugins i installed like the jboss tools or something else which is java ee related.
Re: content type clash [message #638055 is a reply to message #556375] Tue, 09 November 2010 13:57 Go to previous messageGo to next message
Eclipse UserFriend
I recently discovered the same problem trying to work with Eclipse with the JBoss tools installed. It seems that even when trying to open the files with the PHP editor, it still treats them as JSP files. You can easily see the difference by trying to open a file with the ".php" extension versus the ".inc" extension. Apparently, ".inc" is also a valid extension for JSPs and the JSP editor seems bent on treating them as JSP pages no matter what you try to do. Is there some way to force this thing to not do that?
Re: content type clash [message #638069 is a reply to message #638055] Tue, 09 November 2010 15:12 Go to previous messageGo to next message
Eclipse UserFriend
well, what I did was to just use a different instance of eclipse for php (and python) development.
that way there's no clash.. also, I use aptana for that which is (so far) pretty comfortable.
Re: content type clash [message #638080 is a reply to message #638055] Tue, 09 November 2010 15:55 Go to previous messageGo to next message
Eclipse UserFriend
On 11/9/2010 1:57 PM, ikogan wrote:
> I recently discovered the same problem trying to work with Eclipse with
> the JBoss tools installed. It seems that even when trying to open the
> files with the PHP editor, it still treats them as JSP files. You can
> easily see the difference by trying to open a file with the ".php"
> extension versus the ".inc" extension. Apparently, ".inc" is also a
> valid extension for JSPs and the JSP editor seems bent on treating them
> as JSP pages no matter what you try to do. Is there some way to force
> this thing to not do that?

It's still a puzzle as to why it would be doing that--neither the JSP
plug-ins in WTP 3.1 nor WTP 3.2 do anything with *.inc files by default.

--
Nitin Dahyabhai
Eclipse WTP Source Editing and JSDT
IBM Rational
Re: content type clash [message #638116 is a reply to message #638080] Tue, 09 November 2010 19:29 Go to previous messageGo to next message
Eclipse UserFriend
i think it's a jboss tools issue, but i'm not sure. i decided it's much easier to just use different eclipses. it also makes sense to do so.
Re: content type clash [message #647203 is a reply to message #556131] Tue, 04 January 2011 19:56 Go to previous message
Eclipse UserFriend
I have the bug as well, I don't want to install one eclipse instance for every project. Is there any way to specify a configuration ? Loading a set of modules only on certain workspace and disable some such as the inc content type for JSP ?
Previous Topic:GWT plugin not working in helios 3.6
Next Topic:Custom Outline view
Goto Forum:
  


Current Time: Mon Oct 13 15:30:26 EDT 2025

Powered by FUDForum. Page generated in 0.11049 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top