If you want to apply the same action for multiple selectors in jQuery, you should write down their identificators separated by comma. It can be as simple ID of elements, their classes or something more difficult.
Find tag which contains some text you're looking for using jQuery. It's a common task if you want to modify some elements on page but you can't modify html-code of page.
For jQuery 1.6+ use .prop() function. I don't think it's a good idea to support old versions and use .attr() or something like this.
Strange behavior of console.log() I have noticed when I created a JS code for SharePoint page. My code used jQuery and SPServices library. The code used to get items from a list and render options for "select" control.
Below I post a part of my function which fills a JS array and renders options for "select" control.