javascript - Create a div containing target div using jQuery -
I think it should be easy, but I'm not able to work it out. I want to target a div or other element using jQuery and then want to create a device with a dynamically-targeted element, for example:
jQuery ('. Myclass')
How can I create a div with the background-color attribute in which the 'myclus' element is set to white?
Initially I have: & lt; Div class = "myclass" & gt; Some HTML elements & lt; / Div & gt;
And after executing the jQuery call, I have to: Post-text "itemprop =" text "> You can use the function to insert a cover around the matching elements. I prefer to use a square for background, but you can also assign CSS attributes directly to the background. / P> or & lt; Div style = "background-color: #fff" & gt; & Lt; Div class = "myclass" & gt;
$ ('. Myclass'). Rap ($ (' (div = gt; & lt; / div & gt; '). CSS (' background-color ',' # FFF ');. (' (Lt; div> '')) AddClass ('
$ (' . Myclass') White Background '));
Comments
Post a Comment