public function pushLog($key, $val = '', $length = null)
    {
        if (!(is_string($key) || is_numeric($key))) {
            return;
        }
        $key = urlencode($key);
        if (is_array($val)) {
            if ($length) {
                $val = $this->substrLog($val, $length);
            }
            $this->_pushlogs[] = "$key=" . json_encode($val);
        } elseif (is_bool($val)) {
            $this->_pushlogs[] = "$key=" . var_export($val, true);
        } elseif (is_string($val) || is_numeric($val)) {
            if ($length && is_string($val) && strlen($val) > $length) {
                $val = $this->substrLog($val, $length);
            }
            $this->_pushlogs[] = "$key=" . urlencode($val);
        } elseif (is_null($val)) {
            $this->_pushlogs[] = "$key=";
        }
    }