jQuery get content between
tags

前端 未结 8 1334
情歌与酒
情歌与酒 2020-12-05 04:10

This\'ll probably be easy for someone:

var x = \'

blah

相关标签:
8条回答
  • 2020-12-05 04:50

    use jquery for that:

    $("#divId").html()
    
    0 讨论(0)
  • 2020-12-05 04:52

    jQuery has two methods

    // First. Get content as HTML
    $("#my_div_id").html();
    
    // Second. Get content as text
    $("#my_div_id").text();
    
    0 讨论(0)
提交回复
热议问题