Home  >  Article  >  Web Front-end  >  jquery's $("#id").html() has no content solution_jquery

jquery's $("#id").html() has no content solution_jquery

WBOY
WBOYOriginal
2016-05-16 18:25:311861browse

I added $("#id").html("45a2772a6b6107b401db3c9b82c049c2" result "54bdf357c58b8a65c66d7c19c8e4d114");
Just add span! ! !
Record it here.

General solution: Pay attention to whether the name of result is repeated with some built-in ones. It is recommended to use content, etc.

When I write this into a function today, I also need to pay attention to:

function doad(datastr,id){ 
//getid(id).innerHTML = datastr;
$("#"+id).html(datastr);
}

When calling:

<div id="logo_m"></div>
<script>
var lom_m="脚本之家 www.jb51.net";
doad(logo_m,'logo_m');
</script>

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn