Jquery:
$("select.foo option:selected").val();
$("#greatphoto" ).attr( "alt", "Beijing Brush Seller");
$( "p" ).text( "<b>Some</b> new text." );
If I haven't worked in Jquery for a while, I always have to google for how to set attributes and values, if you look at the docs, attr and val as far as I can see are the only two methods with shortened names, everything else is written out in full like text.