<!DOCTYPE html> <html> <head> <meta charset="utf-8" /> <title></title> <style type="text/css"> .col { border:solid 1px #eee; width:200px; } </style> <script src="../Scripts/jquery-1.10.2.min.js"></script> <script type="text/javascript"> $(function(){ $("div").toggleClass("col"); }) </script> </head> <body> <div class="col">123</div> <div>345</div> <div>456</div> </body> </html>