public function widget($theme = null, $type = null, $callback = null, array $attributes = array())
    {
        $attributes['class'] = implode(' ', array_merge((array)(isset($attributes['class']) ? $attributes['class'] : null), ['g-recaptcha']));
        $attributes['data-sitekey'] = $this->siteKey;
        $attributes['data-theme'] = $theme;
        $attributes['data-type'] = $type;
        $attributes['data-callback'] = $callback;

        return '<div' . HtmlBuilder::attributes($attributes) . '></div>';
    }
public function widget($theme = null, $type = null, $callback = null, array $attributes = array())
    {
        $attributes['class'] = implode(' ', array_merge((array)(isset($attributes['class']) ? $attributes['class'] : null), ['g-recaptcha']));
        $attributes['data-sitekey'] = $this->siteKey;
        $attributes['data-theme'] = $theme;
        $attributes['data-type'] = $type;
        $attributes['data-callback'] = $callback;

        return '<div' . HtmlBuilder::attributes($attributes) . '></div>';
    }
public function widget ( $ theme = null , $ type = null , $ callback = null , array $ attributes = array ( ) ) { $ attributes [ 'class' ] = implode ( ' ' , array_merge ( ( array ) ( isset ( $ attributes [ 'class' ] ) ? $ attributes [ 'class' ] : null ) , [ 'g-recaptcha' ] ) ) ; $ attributes [ 'data-sitekey' ] = $ this -> siteKey ; $ attributes [ 'data-theme' ] = $ theme ; $ attributes [ 'data-type' ] = $ type ; $ attributes [ 'data-callback' ] = $ callback ; return '<div' . HtmlBuilder :: attributes ( $ attributes ) . '></div>' ; }
Generates a div tag for the widget based on the options.

@param  string $theme      The color theme of the widget ('dark' or 'light').
@param  string $type       The type of CAPTCHA to serve ('audio' or 'image').
@param  string $callback   The name of the JavaScript callback function to be executed when the user submits a successful CAPTCHA response.
@param  array  $attributes Additional attributes to be placed on the div.
@return string
Generates a div tag for the widget based on the options .