Better jQuery function argument with if-statement?
Without changing too much, here are some tips on improving your code.
Assumptions:

You're working in modern web browser.
left, up, down, right are defined else where.

1)
Define all the variables at the top. I'm not sure where the fucntions left, up, down, right are.
2)
Use a switch instead of multiple if else.
3)
Perform an operation to collection if multiple elements share the same functionality. Refer to resetValues()
4)
Try to make all the if conditions as small as possible. Refer to !key.length
Here's what I came up with.
Array.prototype.forEach = Array.prototype.forEach || function(fn, scope) {
    for(var i = 0, len = this.length; i &lt; len; ++i) {
        fn.call(scope || this, this[i], i, this);
    }
};

var self = this,
    check_left, check_right, check_up, check_down,
    left_itv, right_itv, up_itv, down_itv;
    
var resetValues = function(){
    [&quot;left_itv&quot;, &quot;right_itv&quot;, &quot;up_itv&quot;, &quot;down_itv&quot;].forEach(function(el){
        clearInterval( self[el] );
    });
    [&quot;check_left&quot;, &quot;check_right&quot;, &quot;check_up&quot;, &quot;check_down&quot;].forEach(function(el){
        self[el] = true;
    });
};

resetValues();

function check_itv(key) {
    if (!key.length) {
        return;
    }
    resetValues();
    switch( key ){
        case &quot;left&quot;:
            left_itv = setInterval(left, 100);
            check_left = false;
            break;
        case &quot;right&quot;:
            right_itv = setInterval(right, 100);
            check_right = false;
            break;
        case &quot;up&quot;:
            up_itv = setInterval(up, 100);
            check_up = false;
            break;
        case &quot;down&quot;:
            down_itv = setInterval(down, 100);
            check_down = false;
    }
}

Alternatively, you could swap the global variables inside a singleton(namespace) that has a reset functions. But that add a bit of complexity.