Solved

How to add additional file type to New context menu.

Posted on 2008-06-11
3
1,889 Views
Last Modified: 2013-12-15
Hello.
I'm using Eclipse PDT for php development but it should be the same for Java.
When I'm using right click on file explorer I have New menu to add new file.
Depending on what type of project I;m working (java or php) there are different file types that I can create
for Java there is .java for php there is .php , .html and so on.
I want to add additional file extension .phtml (yes Phtml) .
I know I can add phtml file by using other and simple file then just typing filename.phtml but its more time consuming.

How can I do this?
Is there any configuration file?
Best Regards
FooKy
0
Comment
Question by:f_o_o_k_y
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 8

Expert Comment

by:CoyotesIT
ID: 21763141
Yes you can, here is a great tutorial on adding custom templates, which is what you will need to do.

In Ecplipse click \Window\Preferences and type templates in the search bar

You will then be able to add a new template by selecting the "Templates" under PHP for your new filetype.

http://eclipse.dzone.com/news/effective-eclipse-custom-templ

Good luck!

0
 
LVL 11

Author Comment

by:f_o_o_k_y
ID: 21763370
I don't think so. Or I couldn't understand this.

But using this I can create templates which I can then use by pressing ctl+space
for example to use if else statement.

But I want to be able to create new file in my "solution explorer" I see ther New php file with this code
<?php
${cursor}
?>

But when I added new Phtml and code ${cursor} then nothing happened and I still do not have phtml under right mouse buton in file explorer in eclipse.

I'm not sure but meybe I need to change something in php plugin for eclipse? or something else?
0
 
LVL 8

Accepted Solution

by:
CoyotesIT earned 500 total points
ID: 21763449
Sorry, after trying that myself, i realized that was not the answer you were looking for.

I think this may be more to what you are looking for.

http://www.ibm.com/developerworks/library/os-eclipse-3.3menu/index.html

0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
MySQL limit and not so limited 13 41
Building a glossary into your website 9 22
if statement malfunction 5 23
PHP substring 2 13
Developers of all skill levels should learn to use current best practices when developing websites. However many developers, new and old, fall into the trap of using deprecated features because this is what so many tutorials and books tell them to u…
Jaspersoft Studio is a plugin for Eclipse that lets you create reports from a datasource.  In this article, we'll go over creating a report from a default template and setting up a datasource that connects to your database.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

733 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question