Intellij Idea 2016 not providing template for index.jsp or web.xml file in a simple web app

已回答

Hello, I've created multiple web applications on Intellij Idea Ultimate 2016 version and it never provides the template code for the index.jsp file or the web.xml file. Also when I select JSP while creating a new project it does the same to the faces-config.xml file.

Is there anything I can do to get the template code when I create a new file?

 

 

0

Could you please try with the current version? Do you have JSP/JSPX item in the New menu? Please share the screenshot of the issue showing the New menu options. Also provide the logs (https://intellij-support.jetbrains.com/hc/articles/207241085): https://uploads.jetbrains.com.

0

Serge, I have tried it with the new version but I uninstalled it and got the 2016 version instead as none of my web applications were running on it. There was some problem with the server connections.

 Also, I'm very sorry but I'm not sure how to send the log files. I zipped the files but I don't know how to attach it to this comment. 

0

The issue is not clear.

The files can be created like this:

 

The link to files upload service was provided in the previous reply, please read it again.

1

Here is the upload ID for the log files. I'm sorry I didn't check the second link.

Upload id: 2020_08_14_6Lv9D7MhvRF1vZUt (file: Log Files.zip)

JSP files can be created the way you explained:

However, the initial index.jsp and web.xml files do not have their template codes. Normally when one creates a web application those files have some pre-written code. Could you please tell me how I can get those templates? 

I also have the same problem with the faces-config.xml file when I create a web application with JSP.

Thank you.

0

Your installation appears to be corrupted, try to reinstall from https://www.jetbrains.com/idea/download/previous.html .

The templates can be found here:

0

Yes, I did check the File and Code Templates but none of my files have any pre-written codes:

Are you sure this issue will be resolved by reinstalling it?

Thank you.

0

Your installation files are damaged causing the issue, reinstall should help:

2020-08-14 21:13:08,513 [112926225] ERROR - .impl.FileTemplateConfigurable - Entry fileTemplates//default.html not found in C:/Program Files (x86)/JetBrains/IntelliJ IDEA 2016.2.2/lib/resources_en.jar 
java.io.FileNotFoundException: Entry fileTemplates//default.html not found in C:/Program Files (x86)/JetBrains/IntelliJ IDEA 2016.2.2/lib/resources_en.jar
at com.intellij.util.io.URLUtil.openJarStream(URLUtil.java:101)
at com.intellij.util.io.URLUtil.openStream(URLUtil.java:62)
at com.intellij.ide.fileTemplates.impl.UrlUtil.loadText(UrlUtil.java:46)
at com.intellij.ide.fileTemplates.impl.FileTemplateConfigurable.reset(FileTemplateConfigurable.java:338)
at com.intellij.ide.fileTemplates.impl.FileTemplateConfigurable.setTemplate(FileTemplateConfigurable.java:119)
at com.intellij.ide.fileTemplates.impl.AllFileTemplatesConfigurable.e(AllFileTemplatesConfigurable.java:411)
at com.intellij.ide.fileTemplates.impl.AllFileTemplatesConfigurable.access$000(AllFileTemplatesConfigurable.java:66)
at com.intellij.ide.fileTemplates.impl.AllFileTemplatesConfigurable$4.onTemplateSelected(AllFileTemplatesConfigurable.java:219)
at com.intellij.ide.fileTemplates.impl.FileTemplateTabAsTree$1.valueChanged(FileTemplateTabAsTree.java:62)
1

Hello, I'm sorry but I installed another version from the link you sent me but I'm still having the same problem. There are no templates available in the File and Code Templates.

0

Try to reinstall again with the antivirus disabled, something corrupts resources_en.jar file.

0

I tried that too, it's still not working.

0

See if you can reproduce it on any other machine, there is some issue with your system corrupting IDE files.

0

请先登录再写评论。