I have some data enclosed in HTML tags. I want to insert this data into a database table as plain text, without the HTML tags in it.
Could you please provide any MySQL code that will remove the HTML tags, either when inserting the data, or when retrieving the data.
The insertion and retrieval of the data occurs from a JSP page.
It’s usually a recommendable practice to only sanitize HTML when you need to view it, otherwise store the HTML “as is” in the database.
For removing html tags, you can use htmlCleaner