Ah, terminate the string! I'll give that a shot, thanks much for the
extra set of eyes. I came up with an alternate solution that works
but I like the :gt and :lt way better. Here's what I came up with:
var condition_count = $('#filterlist_wrapper ul#col1 li').size(),
left_col = condition_count / 2,
right_col = condition_count - left_col,
column1,
column2,
right;
left_col = Math.ceil(left_col);
right_col = Math.floor(right_col);
//console.log('left:' + left_col + ' right:' + right_col);
column1 = $('#filterlist_wrapper ul#col1');
column2 = $('');
right = $('#filterlist_wrapper ul#col1 li').slice(right_col);
column2.html(right).insertAfter(column1);
On Nov 17, 6:51 pm, mkmanning wrote:
> Try $('#filterlist_wrapper ul li:gt('+left_col+')')
>
> On Nov 17, 3:35 pm, Magnificent
>
> wrote:
> > It should read:
>
> > > I'm storing my counts in variables, but it doesn't look like :gt
> > > and :lt can accept a VARIABLE value as it's parameter.
>
> > It works when I put in, say :gt(44), but not :gt(left_col) or lt:
> > (right_col) when those variables are numbers.