How to change the heading of an accordion with a plus and minus symbol?

I don’t like the default Accordion badges, and I want to change them. This link is here:

http://jqueryui.com/demos/accordion/#option-header

shows the ability to change the title, but for this you need to specify icons. I do not need badges. I just need simple (+)and(-)

How can I do this with accordions?

+5
source share
1 answer

Hiya working demo of examples http://jsfiddle.net/zM5Vj/ or http://jsfiddle.net/zM5Vj/show/

Hope this helps, + will be shown when the accordion collapses, where as is in the case of an open accordion.

there is good!

JQuery, + - , . , . , , !

$(function(){
 $('#accordion .fullChild>a.opener').text('+').addClass('box');

  $('#accordion .opener').click(function() {
  if($(this).text() == "-") {
  $(this).text("+");
  }
  else {
  $('#accordion .opener').text("+");
  $(this).text("-");
  }
});
});
+5

All Articles