I want to accept, to accept the html input from the user and publish it on my site, I also want to make sure that it does not create a problem with my site template due to the dirty html code.
I have used the html cleaner in the past, but the Html cleaner does not work on one of my servers. Therefore, I am looking for a better alternative. What is written in php. which can fix dirty html code like
</div> it is dirty code as div is closed without opening.
You can try PHP Tidy , which is a Tidy library in PHP.
: DOMDocument loadHTML . <html> <body>, . , , HTML.
DOMDocument
loadHTML
<html>
<body>
, , . URL-, , , http:, , javascript:. , , ( - , ).
http:
javascript:
, node , saveHTML. DOM, - , , .
saveHTML
, Tidy , , HTML Purifier, , (, JavaScript onclick events ..).
Remember that Tidy requires libtidy to be installed on your server, so this is not just direct PHP.
I know that PΓ‘draic Brady is working on an alternative to HTML Purifier for the Zend Framework, although I think its just experimental code at this time
http://framework.zend.com/wiki/pages/viewpage.action?pageId=25002168
http://github.com/padraic/wibble
Source: https://habr.com/ru/post/1772011/More articles:How to define parameter names for higher order functions in C # - c #Atlantian Help Jira SVN Plugin - jiraHow to select rows in which several related table values ββmeet the selection criteria? - sqlper pixel collision using getRGB BufferedImage (Java2D Api) - collision-detectionBuild code mixed with my C ++ code. How to transfer up to 64 bits - c ++cross-platform way to examine the contained file folder - javahttps://translate.googleusercontent.com/translate_c?depth=1&pto=aue&rurl=translate.google.com&sl=ru&sp=nmt4&tl=en&u=https://fooobar.com/questions/1772013/is-svns-relocate-a-safe-option-to-synchronize-code-with-two-subversion-repositories&usg=ALkJrhhm7z6MnbytLE4evcnq1NxfuGrUVgWhat exception can be raised if the given line does not correspond to some format? - pythonHow to select QGraphicsItem without selecting the whole group (to which this element belongs) - selectevent when a window is closed, but not closing it - javaAll Articles