```
    <div class="tovar_color_select">
                    <p>Select color</p>
                     <?php $hn = new product();
                      $get_color = $hn->get_color_id_nullval($gg['id_product']);
                      while($fetch_color = mysql_fetch_array($get_color)){
                         ?>
                     <a class="color"  title="<?=$fetch_color[1]?>" 
onClick="chkcolor(this , <?=$gg['id_product']?> , <?=$fetch_color[0]?>)" 

style="background-color:<?=$fetch_color[2]?>" ></a>
                    <?php } ?>
                </div>
    function chkcolor(obj,p_id,clr_id){

            if($(obj).hasClass("active") )
            {
                $(obj).removeClass("active");
                $('.tovar_color_select a').removeClass("active");
            }

            else {

                $(obj).addClass('active');
            }

            }

```

Listen carefully about my query .I am already successfully in getting active class and also have remove active class of current object but I need to remain active other select DOM element which is select by user .Currently my code remove from all DOM element active class.I just want remain select class active other DOM elements should have to removed from active class.if currently i have any syntax mistake you can mentioned but also you have give me some logical implementation of my query. Thanks in Advance for help