Skip to main content



      Home
Home » Language IDEs » Java Development Tools (JDT) » How to replace jsp comments with html comments(search and replace patter)
icon14.gif  How to replace jsp comments with html comments [message #1701755] Wed, 15 July 2015 08:26 Go to next message
Eclipse UserFriend
I have a requirement to replace all html comments in all jsp file in my work space with jsp comments. I need to search for all and replace with <%-- --%> and I should not loose the comments.

For Eg

<!-- I have a comment here --> should be replaced with.
<%-- I have a comment here --%>
I am using eclipse to do this. Please let me know if I have some other better way to do it.
Re: How to replace jsp comments with html comments [message #1702054 is a reply to message #1701755] Sat, 18 July 2015 01:33 Go to previous messageGo to next message
Eclipse UserFriend
Why don't you simply add a task in your build process that makes sure that no JSP contains <!--? That would be extremely simple to implement, it would educate your developers, it would cost nothing at runtime, and it wouldn't tie your solution to any specific tomcat implementation.
Re: How to replace jsp comments with html comments [message #1702069 is a reply to message #1702054] Sat, 18 July 2015 12:24 Go to previous message
Eclipse UserFriend
I can do that, but need to remove all the comments for now, i tried $1 but it is not working
Previous Topic:Eclipse mars + buildship problem
Next Topic:Eclipse: Java [ Not Detecting Key Pressed ]
Goto Forum:
  


Current Time: Mon Jul 14 14:32:28 EDT 2025

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

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

Back to the top