jquery has a powerful way to manipulate HTML elements and attributes.
A very important part of this is the ability to manipulate the DOM.
dom--the Document Object model.
1 <!DOCTYPE HTML>2 <HTML>3 <Head>4 <MetaCharSet= "Utf-8">5 <Scriptsrc= "Https://cdn.bootcss.com/jquery/1.10.2/jquery.min.js"></Script>6 <Scripttype= "Text/javascript">7 $(function(){8 $("#btn1"). Click (function(){9 Alert ("Text:"+$("#test"). text ());Ten }) One $("#btn2"). Click (function(){ A Alert ("HTML:"+$("#test"). HTML ()); - }) - $("#btn3"). Click (function(){ the Alert ("values:"+$("#test2"). Val ()); - }) - $("#btn4"). Click (function(){ - Alert ("href Value:"+$("#a1"). attr ("href")); + }) - }) + </Script> A </Head> at - <Body> - <PID= "Test">This is in the paragraph<b>Bold</b>Text.</P> - <P>Name:<inputtype= "text"ID= "Test2"value= "You and I, he learns." /></P> - <P><ahref= "Www.nwtxxb.com"ID= "A1">You and me, he learns.</a></P> - <ButtonID= "Btn4">Displays the value of the href attribute</Button> in <ButtonID= "Btn3">Show Values Value</Button> - <ButtonID= "BTN1">Display text</Button> to <ButtonID= "BTN2">Display HTML</Button> + </Body> - </HTML>
"Learn to light it" jQuery DOM operations-get content and properties