Jump to content

problema com xmlhttp no ie

Recommended Posts


Boa tarde,

Utilizo esta função para fazer pesquisas dinâmicas numa tabela.

function EnviaFornecedores(fornecedores,empresas,pesquisa,contratos)
document.getElementById("fornecedores").value = fornecedores;
document.getElementById("empresas").value = empresas;
document.getElementById("contratos").value = contratos;

if (window.XMLHttpRequest)
 {// code for IE7+, Firefox, Chrome, Opera, Safari
xmlhttp=new XMLHttpRequest();
 {// code for IE6, IE5
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
 if (xmlhttp.readyState==4 && xmlhttp.status==200)


Funciona perfeitamente e envia bem os dados, no entanto (principalmente no ie) se fizer refresh à página não me mostra a tabela e o problema está nesta função. Alguma ideia ?

Estranha forma de vida que tem a capacidade de transformar comandos em mensagens de erro.


Share this post

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...

Important Information

By using this site you accept our Terms of Use and Privacy Policy. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.