zohab Posted March 31, 2011 Share Posted March 31, 2011 Hi, I want to get selected class in div java script. how can i get it. following is the code of div <div id="" class="ui-accordion"> <div class="groupdiv"><div> <div class="title"></div> <div class="groupdiv selected"><div> <div class="title selected"></div> <div class="groupdiv"><div> <div class="title"></div> </div> Link to comment https://forums.phpfreaks.com/topic/232265-how-to-get-selected-class-in-div-value-java-script/ Share on other sites More sharing options...
Adam Posted March 31, 2011 Share Posted March 31, 2011 What do you mean? Link to comment https://forums.phpfreaks.com/topic/232265-how-to-get-selected-class-in-div-value-java-script/#findComment-1194845 Share on other sites More sharing options...
zohab Posted March 31, 2011 Author Share Posted March 31, 2011 I mean,what could be the statement in javascript to get value between div <div class="title selected"></div> function check_custom_data() { alert(document.getElementById('groupdiv').value) ; alert(document.getElementById('title selected').value) ; alert(document.getElementTagName('.title selected').value) ; } Link to comment https://forums.phpfreaks.com/topic/232265-how-to-get-selected-class-in-div-value-java-script/#findComment-1194849 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.