This is a very basic method to log some stuff by using the error_log() method of PHP.

@param mixed  $level   The log level to use
@param string $message The message we want to log
@param array  $context The context we of the message

@return void
356441
public function log($level, $message, array $context = array())
    {
        error_log(sprintf($this->getDefaultLogFormat(), date('Y-m-d H:i:s'), gethostname(), $level, $message, json_encode($context)));
    }
161868
public function log($level, $message, array $context = [])
    {
        if (in_array($level, $this->acceptedLevels, true)) {
            $this->logger->log($level, $message, $context);
        }
    }
947455
public static function log($level, $message, array $context = array())
    {
        App::getBean('Logger')->log($level, $message, static::parseContext($context));
    }
839749
public function log($level, $message, array $context = [])
    {
        $record = new LogRecord($level, $message);

        // add all messages to session log
        $this->session->addRecord($record);

        // write record into log only if it is enough by level
        if ($this->logLevel >= $level) {
            $this->write($record);
        }
    }
1321424
public function log($level, $message, array $context = array()) {
        $realMessage = rtrim(static::interpolate($message, $context), "\n");

        if (isset($context['event'])) {
            $realMessage = sprintf("<%s> %s", $context['event'], $realMessage);
        }

        $realMessage = sprintf("[%s] %s\n", $level, $realMessage);

        syslog($level, $realMessage);
    }
660282
public function log($level, $message, array $context = array())
    {
        $message = $this->formatMessage($level, $message, $context);        
        $this->write($message);
    }
1140768
public function log($message, $level = LogLevel::INFO, $context = array())
    {
        $this->buildLogger->log($message, $level, $context);
    }
54599
public function log($level, $message, array $context = []) {
		if (!Logger::check($level)) {
			return;
		}
		if (count($context) > 0) {
			foreach ($context as $k => $v) {
				$message = str_replace('{' . $k . '}', $v, $message);
			}
		}
		$content = sprintf("%s | %s | %s | %s", date('Y-m-d H:i:s'), $this->getLevel($level), microtime(true), $message);
		co::fwrite($this->handler, $content);
	}
1360766
public function log($level, $message, array $context = array())
  {
    $this->Web2All->debugLog('['.$level.'] '.$this->interpolate($message, $context));
  }
239600
public function log($level, $message, array $context = array())
    {
        $allContext = array_merge($this->extraContext, $context);

        $this->logger->log($level, $message, $allContext);
    }
553217
public function log($level, $message, array $context = array())
    {
        $meta = [
            'datetime' => date($this->dateFormat),
            'name'     => $this->name,
            'level'    => $level,
            'message'  => $this->formatMessage($message, $context),
            'context'  => $this->formatContext($context)
        ];

        $message = $this->interpolate($this->getMessageFormat($level, $context), $meta);

        fwrite($this->stream, $message . PHP_EOL);
    }
994369
public function log($level, $message, array $context = []) {
        $realMessage = rtrim(static::interpolate($message, $context), "\n");
        $levelC = strtoupper(substr($level,0,1));
        $realMessage = sprintf("[ %1s ] %s\n", $levelC, $realMessage);

        fwrite($this->fr, $realMessage);
    }
867361
public function log($level, $message, array $context = [])
    {
        if (!isset($this->logLevels[$level])) {
            $level = LogLevel::DEBUG;
        }

        if ($this->logLevels[$level] < $this->level) {
            // do not print.
            return;
        }

        if ($this->level === 3 && $this->logLevels[$level] === 3) {
            $style = 'dim';
        } else {
            $style = $this->levelStyles[$level];
        }

        if ($this->indent) {
            $this->write(\str_repeat($this->indentCharacter, $this->indent));
        }

        if (\is_object($message) || \is_array($message)) {
            $this->writeln(\print_r($message, true), $style);
        } else {
            $this->writeln($message, $style);
        }
    }
557160
public function log($level, $message, array $context = [])
    {
        /** @var LoggerInterface|AdapterInterface $logTarget */
        foreach ($this->logTargets as $logTarget) {
            if (($logTarget instanceof AdapterInterface)) {
                $logTarget->log($this->getPhalconLoggerLevel($level), $message, $context);
            } else {
                $logTarget->log($level, $message, $context);
            }
        }
    }
179330
public function log($level, $message, array $context = array()) {
		try {
			if($this->messageType === null) {
				error_log($message);
			} elseif((int)$this->messageType === 0 || (int)$this->messageType === 4) {
				error_log($message, $this->messageType);
			} else {
				error_log($message, (int)$this->messageType, $this->destination, $this->extraHeaders);
			}
		} catch(\Exception $e) {
		}
	}
902698
public function log($level, $message, array $context = array())
    {
        if (isset($this->levels[$level]) && $this->levels[$level] < $this->minLevel) {
            return;
        }
    
        if (!empty($this->context) || !empty($context)) {
            $context = array_merge($this->context, $context);
        }
        
        if ($this->prefix !== '') {
            $this->logger->log($level, $this->prefix . $message, $context);
        } else {
            $this->logger->log($level, $message, $context);
        }
    }
737881
public function log($level, $message, array $context = array())
    {
        if (!LogLevel::isValidValue($level)) {
            throw new \InvalidArgumentException('Invalid loge level: '.$level);
        }

        $timestamp = time();

        $log = sprintf(
            '[%s] %s %s',
            date('Y-m-d H:i:s', $timestamp),
            strtoupper($level),
            self::interpolate($message, $context)
        );

        error_log($log);
    }