HTML CSS examples for CSS Selector:after
Selecting the direct first element after another element in CSS
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> textarea + span { color:Chartreuse; } </style> <!--from w ww . j av a 2 s . c o m--> <script type="text/javascript"> </script> </head> <body> <div id="form"> <form> <textarea id="text"></textarea> <span class="error">Lorem ipsum</span> <span class="error">Lorem ipsum dolor</span> </form> </div> </body> </html>