Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

find() and attr() in prototypejs

What are equivalent of jQuery function find() and attr() in prototypejs?

Could someone help me to convert this code using prototypejs?

var className = $(this).find('.myBtn').attr('class');
$(this).find('.tab').attr('class', className + ' current');

Thanks in advance!

like image 911
Jeaf Gilbert Avatar asked Dec 13 '22 13:12

Jeaf Gilbert


1 Answers

For others searching and landing here: I think Prototype's Element.select() would be a better fit as a jQuery $.find() equivalent.

like image 121
maryisdead Avatar answered Dec 29 '22 15:12

maryisdead