1

this is the graph and i need to hide the dates

how can i hide the date on the graph

<div class="highcharts-container" id="highcharts-6">
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="1330"   height="532"><desc>Created with Highstock 1.3.7</desc><defs><clipPath id="highcharts-7"><rect fill="none" x="0" y="0" width="1239" height="290"></rect></clipPath></defs>
<path fill="none" d="M 71 45 L 71 335 180 335 180 45" zIndex="5"></path>
<text x="126" y="29" transform="translate(0,0)" visibility="visible">
<tspan x="126">7/9/15</tspan></text></svg></div>
j08691
  • 204,283
  • 31
  • 260
  • 272
Nisha Nethani
  • 109
  • 1
  • 1
  • 11

1 Answers1

2

If there's just one, then this code should work:

document.querySelector("tspan").style.display = "none";

If there are multiple then:

[].forEach.call(document.querySelectorAll("tspan"), function(item) {
  item.style.display = "none";
});

Or if you want to use jQuery:

$("tspan").hide();
Dave
  • 10,748
  • 3
  • 43
  • 54