jquery get value inside html element

 

 

 

 

The text() in jQuery is equal to innerHTML and html() function which returns the plain html inside an element.Using attr() function in jquery we can get and set the attributes of html elements. Syntax: For getting attribute value Get the DOM element display text ( between tags ) using the element value. Solution Code. var fieldText (fieldId option[ value" fieldValue "]).text() Is it possible to get text "The First Item" by using jquery?