var multi_quote_posts = [] ;

function switch_multiquote ( tid, _id )
{
    var cls = '' ;
    
    var obj =  $('#quote_button_'+_id) ;
    
    if ( obj.attr('className') == 'multi_quote_bt_active' )
    {
        if ( multi_quote_posts[_id] != undefined )
        {
            multi_quote_posts[_id] = undefined ;
            delete multi_quote_posts[_id] ;
        }
        
        cls = 'multi_quote_bt' ;
    }
    else
    {
        multi_quote_posts[_id] = true ;
        cls = 'multi_quote_bt_active' ;
    }
    
    $.post (
         fm_base_url+'background/ajax/refresh_quote_marks.htm',
         { tid:tid, data:serialize(multi_quote_posts) },
         function ( msg )
         {
             obj.attr('className', cls ) ;
         }
     )
}
