Changing a DATA-ICON in jQuery MobileStarted playing with jQuery Mobile last night. Friends have been wanting me to make a tournament app that will help us stay organized when playing ping pong on Monday Nights. I said ping pong, not beer pong. Second question is always…. “Do you guys hit it from like 20 feet back?” Sure, if the garage was big enough, it would be like that, but we are somewhat limited. There are occasions when one side can get that far back. As the rambling goes on I will go ahead and say it seems that jQuery Mobile doesn’t have a way to just change the data-icon using the
.attr('data-icon', 'plus');. Of course I would fight with it for about 45 minutes. Well, I wanted to get this down here this morning so that I could make sure I would follow up with an answer here as soon as I figure it out! If you want to see what is going on so far – http://jsbin.com/udaziy/11/edit Oh yeah. So I was being silly.
$(this) .find('.ui-icon') .addClass('ui-icon-delete') .removeClass('ui-icon-plus');I was targeting the wrong
Trackback from your site.