das funktioniert ..jquery Variablensubstitution
$("select[title='First Choice'] option[text='hello']").remove();
Eine Anzahl von Variationen dieser nicht .. Ich weiß, das ist dumm.
var what='hello';
$("select[title='First Choice'] option[text=$what]").remove();
auch diese versucht.
$("select[title='First Choice'] option[text=$(what)]").remove();
$("select[title='First Choice'] option[text='$what']").remove();
$("select[title='First Choice'] option[text=$what.val()]").remove();
Dieses Javascript ist nicht php ... diese Art von Textersetzung nicht einmal gelten. Sie müssen manuell in die Zeichenfolge einfügen. – mellamokb