code: public function asUrl($value, $options = [])
      {
          if ($value === null) {
              return $this->nullDisplay;
          }
          $url = $value;
          if (strpos($url, '://') === false) {
              $url = 'http://' . $url;
          }
  
          return Html::a(Html::encode($value), $url, $options);
      }
docs: Formats the value as a hyperlink.
  @param mixed $value the value to be formatted.
  @param array $options the tag options in terms of name-value pairs. See [[Html::a()]].
  @return string the formatted result.