jQuery Style How to - Remove border








Question

We would like to know how to remove border.

Answer


<!--  w  w  w  .ja v  a 2  s .c  o  m-->
<!DOCTYPE html>
<html>
<head>
<script type='text/javascript'
  src='http://code.jquery.com/jquery-1.6.3.js'></script>
<style type='text/css'>
div {
  border: 1px solid red;
}
</style>
<script type='text/javascript'>
$(window).load(function(){
    $('.ui-widget-content').not('#helpDialog').css('border','none');
});
</script>
</head>
<body>
  <div class="ui-widget-content">test1</div>
  <div class="ui-widget-content" id="helpDialog">test2</div>
</body>
</html>

The code above is rendered as follows: