Quantcast
Channel: Developer topics
Viewing all articles
Browse latest Browse all 18014

Trouble with adding checkbox

$
0
0

Hi everyone,

 

I wanted to add checkbox and tried this code:

svg.selectAll("foreignObject").data(nodes).enter().append("foreignObject").attr('x', o.x).attr('y',  o.y).attr('width',50).attr('height',20).append("xhtml:body").html("<form><input type=checkbox id=check></input></form>").on("click",function(d, i){            console.log(svg.select("#check").node().checked)});

How it can be added using "input"?

 

 


Viewing all articles
Browse latest Browse all 18014

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>