I created a script to try to remove unsafe content at the time of injecting DOM (I'm using in extensions / addons for browsers):
var str = "<strong>Hello</strong> mundo <script src="http://site/badscript.js"></script...
A curiosity: I wonder if the window is rendered by dom when loading the window, since the document is usually window.document.html . Or does dom come after this parameter?
I'm trying this way
libxml_use_internal_errors(true);
//pegar o conteudo de um pagina web
$doc = new DomDocument();
$doc->loadHTMLFile('http://www.astralsaudeambiental.com.br/');
$div = $doc->getElementById('sidebar');
$string_div = '';...
I've always put the scripts and links to the CSS at the top of the document in the head of the document. Now I realize that there is another concept in which the calls to scripts and CSS are at the bottom of the document html , in the last...
Is there a problem in adding custom properties directly to the [Node] element? For example:
document.getElementById('minhaDiv').minhaPropriedade = 'teste';
I'm using Firefox and have had no problems setting up or getting ownership, but is i...
I'm working with functions in which I must pass ( Mandatory ) a DOM element.
This function will work with the properties of this DOM element.
Example
function changeValue(elem, value){
elem.value = value;
}
var input = document.g...
I am making a "technical resource" to be able to return the status of the SEFAZ servers issuing invoices using PHP. For this, I have so far the code below:
function get_content($URL){
$ch = curl_init();
curl_setopt($ch, CURLOPT_RETURNT...
Reading about regular expression I saw a recurring term, DOM parser, and I had the doubts:
What is DOM PARSER?
How does it work?
Does any language have?