Created
November 9, 2014 23:03
-
-
Save richjava/f2fd0c91405ee27d6b64 to your computer and use it in GitHub Desktop.
Creating .phtml files in Netbeans
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
It is common practice to use .phtml files for view-related files but Netbeans (as at version 8.0) doesn't have out-of-the-box functionality to directly add them to a project. However, Netbean's Templates allow you to specify this functionality: | |
Firstly, create a folder called "Netbeans Templates" on your local machine with two files inside: "PHTML File.phtml" and "PHTML Web Page.phtml". Customize these files to your liking. | |
Go to Tools > Templates > PHP > Add, and then choose your file (do this for both). | |
The new item will be added but it will have the .phtml extension in the name (which we don't want). You can remove the extension by clicking on the file name and then clicking the Rename button. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment