开发者

Html include inside Jquery

开发者 https://www.devze.com 2023-01-10 01:04 出处:网络
Can i place html include inside Jquery? Here is the code: $(document).ready(function(){ $(\".photo\").hoverIntent(function() {

Can i place html include inside Jquery?

Here is the code:

    $(document).ready(function(){

$(".photo").hoverIntent(function() {
    $(this).html('CAN I PLACE HERE A HTML INCLUDE?');
}, function() {
    $(this).html('<img src="' + $(this).attr("title") + '" width="248" height="186" style="border-bottom: 1px solid #2B2B2B开发者_开发技巧;"/>');
});

});


Use the load function:

$(this).load('file.html');


Not good, when i use load(file.html); it reddirects my site to that file only.

I just want to replace certain html on my page with jquery

0

精彩评论

暂无评论...
验证码 换一张
取 消