Set the hidden captcha tags to put in your form.

@param string $mustBeEmptyField

@return string
186372
public static function render($mustBeEmptyField = '_username')
    {
        $ts = time();
        $random = Str::random(16);

        // Generate the token
        $token = [
            'timestamp'         => $ts,
            'session_id'        => session()->getId(),
            'ip'                => request()->ip(),
            'user_agent'        => request()->header('User-Agent'),
            'random_field_name' => $random,
            'must_be_empty'     => $mustBeEmptyField,
        ];

        // Encrypt the token
        $token = Crypt::encrypt(serialize($token));

        return (string) view('hiddenCaptcha::captcha', compact('mustBeEmptyField', 'ts', 'random', 'token'));
    }
1183098
function() {
        if (this.textarea.element.form) {
          var hiddenField = document.createElement("input");
          hiddenField.type   = "hidden";
          hiddenField.name   = "_wysihtml5_mode";
          hiddenField.value  = 1;
          dom.insert(hiddenField).after(this.textarea.element);
        }
    }
1258506
public static function addCustomSubmitBtn($tag)
    {
        $tag = new FormTag($tag);

        $class = wpcf7_form_controls_class($tag->getType());

        $atts = [];

        $atts['class'] = $tag->get_class_option($class).' btn';
        $atts['id'] = $tag->get_id_option();
        $atts['tabindex'] = $tag->get_option('tabindex', 'int', true);

        $value = isset($tag->values[0]) ? $tag->values[0] : '';

        if (empty($value)) {
            $value = __('Send', 'contact-form-7');
        }

        $atts['type'] = 'submit';
        $atts['value'] = $value;

        $atts = wpcf7_format_atts($atts);

        $html = sprintf('<button type="submit" %1$s>%2$s</button>', $atts, $value);

        return $html;
    }
905093
public function getTitle($allowBasicTags = false)
    {
        $titleParts = [];

        if ($allowBasicTags === true) {
            $allowedTags = '<b><del><em><i><strong><s>';
        } else {
            $allowedTags = '';
        }

        foreach ($this->getTitleColumnName() as $fieldName) {
            // Make sure we add strings only, as some fields may be an array or DateTime.
            $value = is_array($this->values[$fieldName]) ? implode(' ', $this->values[$fieldName]) : (string) $this->values[$fieldName];
            if (strip_tags($value, $allowedTags) !== '') {
                $titleParts[] = strip_tags($value, $allowedTags);
            }
        }

        if (!empty($titleParts)) {
            $title = implode(' ', $titleParts);
        } else {
            // nope, no title was found.
            $title = '';
        }

        return $title;
    }
153255
public function __toHtml($submitted = false, $blnSimpleLayout = false, $blnLabel = true, $blnDisplayErrors = true, $intCount = 0)
    {
        $strName = ($intCount == 0) ? $this->__name : $this->__name . "_" . $intCount;
        $strId = ($intCount == 0) ? $this->__id : $this->__id . "_" . $intCount;

        $blnError = ($submitted && ! $this->__validator->validate($intCount) && $blnDisplayErrors) ? true : false;

        if (! $blnSimpleLayout) {
            // *** We asume that all dynamic fields greater than 0 are never required.
            if ($this->__validator->getRequired() && $intCount == 0) {
                $this->setMeta("class", "vf__required");
            } else {
                $this->setMeta("class", "vf__optional");
            }

            // *** Set custom meta.
            if ($blnError) {
                $this->setMeta("class", "vf__error");
            }

            if (! $blnLabel) {
                $this->setMeta("class", "vf__nolabel");
            }

                // Call this right before __getMetaString();
            $this->setConditionalMeta();

            $strOutput = "<div{$this->__getMetaString()}>\n";

            if ($blnError) {
                $strOutput .= "<p class=\"vf__error\">{$this->__validator->getError($intCount)}</p>";
            }

            if ($blnLabel) {
                $strLabel = (! empty($this->__requiredstyle) && $this->__validator->getRequired()) ? sprintf($this->__requiredstyle, $this->__label) : $this->__label;
                if (! empty($this->__label)) {
                    $strOutput .= "<label for=\"{$strId}\"{$this->__getLabelMetaString()}>{$strLabel}</label>\n";
                }
            }
        } else {
            if ($blnError) {
                $this->setMeta("class", "vf__error");
            }

            $this->setMeta("class", "vf__multifielditem");

            // Call this right before __getMetaString();
            $this->setConditionalMeta();

            $strOutput = "<div{$this->__getMetaString()}\">\n";
        }

        // *** Fixing an unusual uploading bug.
        $intMaxFileSize = $this->convertToBytes(ini_get("upload_max_filesize"));
        $strOutput .= "<input type=\"hidden\" name=\"MAX_FILE_SIZE\" value=\"{$intMaxFileSize}\" />";

        $arrValues = [];
        $strValue = $this->__getValue($submitted, $intCount);
        if (!is_array($strValue)) {
            $strValue = htmlspecialchars($strValue, ENT_QUOTES);
            if (!empty($strValue)) {
                $arrValues = [$strValue];
            }
        } else {
            foreach ($strValue as $value) {
                $value = htmlspecialchars($value, ENT_QUOTES);
                $arrValues[] = $value;
            }
        }
        
        //*** Render the file input. We don't set a value for it.
        $strOutput .= "<input type=\"file\" name=\"{$strName}[]\" id=\"{$strId}\"{$this->__getFieldMetaString()} />\n";
        
        //*** Render sanitized values as hidden inputs.
        $intCount = 1;
        foreach ($arrValues as $strValue) {
            $strOutput .= "<input type=\"hidden\" name=\"{$strName}[]\" id=\"{$strId}-{$intCount}\" value=\"{$strValue}\" />\n";
        
            $intCount++;
        }
        
        if (! empty($this->__tip)) {
            $strOutput .= "<small class=\"vf__tip\"{$this->__getTipMetaString()}>{$this->__tip}</small>\n";
        }

        $strOutput .= "</div>\n";

        return $strOutput;
    }
71301
protected function renderHiddenInput()
    {
        if ($this->hasModel()) {
            return Html::activeHiddenInput($this->model, $this->attribute, $this->inputOptions);
        } else {
            return Html::hiddenInput($this->name, $this->value, $this->inputOptions);
        }
    }
1148063
public static function generateHiddenInputFields($pairs)
    {
        $html = '';
        
        foreach ($pairs as $name => $value)
        {
            $html .= self::generateHiddenInputField($name, $value);
        }
        
        return $html;
    }
950026
def captcha_field(object_name, options = {})
      options.delete(:id)

      hidden_field(object_name, :captcha_challenge, options) + text_field(object_name, :captcha_solution, options)
    end
1259630
public function form_button($params) {
        if (!isset($params['field'])) {
            throw new \UnexpectedValueException("The field parameter is required.");
        }
        $value = isset($params['value']) ? $params['value'] : null;
        $attributes = isset($params['attrs']) ? $params['attrs'] : array();
        return Form::button($params['field'], $value, $attributes);
    }
843594
public function setMust(MustQuery $must)
    {
        $this->result = array_merge($this->result, $must->toArray()['bool']);

        return $this;
    }
1318419
protected function maskedTextField()
	{
		$this->setPlaceholder();
		echo $this->getPrepend();
		echo $this->form->maskedTextField($this->model, $this->attribute, $this->data, $this->htmlOptions);
		echo $this->getAppend();
	}
294109
public function form(Form $form)
    {
        $tag = new Tag('form');
        $tag->setAttribute('action', $form->getAction());
        $tag->setAttribute('accept', $form->getAccept());
        $tag->setAttribute('accept-charset', $form->getAcceptCharset());
        $tag->setAttribute('enctype', $form->getEnctype());
        $tag->setAttribute('method', $form->getMethod());
        $tag->setAttribute('target', $form->getTarget());

        $html = $this->parseTag($tag, $form);

        $fields = $form->getFieldsByClass('HiddenField');

        if (sizeof($fields) > 0) {
            $html .= '<ins>' . PHP_EOL;

            foreach ($fields as $field) {
                // hidden fields
                $tag = new Tag('input');
                $tag->setAttribute('type', 'hidden');

                $html .= $this->parseTag($tag, $field) . PHP_EOL;
            }
            $html .= '</ins>' . PHP_EOL;
        }

        return $html;
    }
1250005
function toHTML()
    {

        return '<div class="captcha-container"><img src="' . $this->form_properties['assets_url'] . 'process.php?captcha=' . ($this->form_properties['captcha_storage'] == 'session' ? 2 : 1) . '&amp;nocache=' . time() . '" alt=""' . ($this->form_properties['doctype'] == 'xhtml' ? '/' : '') . '><a href="javascript:void(0)" title="' . $this->form_properties['language']['new_captcha'] . '">' . $this->form_properties['language']['new_captcha'] . '</a></div>';
    
    }
369938
def construct_form_html(hidden_fields, bucket, secure = true, html_options = {}, &block)
      # now build the html for the form
      form_tag(secure == false ? "http://#{bucket}.s3.amazonaws.com" : "https://#{bucket}.s3.amazonaws.com", build_form_options(html_options)) do
        hidden_fields.map do |name, value|
          hidden_field_tag(name, value)
        end.join.html_safe + "
        <!-- The fileupload-buttonbar contains buttons to add/delete files and start/cancel the upload -->  
        <div class='row fileupload-buttonbar'>
          <div class='col-lg-7'>
            <span class='btn btn-success fileinput-button'>
              <i class='glyphicon glyphicon-plus'></i>
              <span>Add files...</span>
              ".html_safe +
              file_field_tag(:file, :multiple => true) + "
            </span>
            <button type='submit' class='btn btn-primary start'>
              <i class='glyphicon glyphicon-upload'></i>
              <span>Start upload</span>
            </button>
            <button type='reset' class='btn btn-warning cancel'>
              <i class='glyphicon glyphicon-ban-circle'></i>
              <span>Cancel upload</span>
            </button>
            <button type='button' class='btn btn-danger delete'>
              <i class='glyphicon glyphicon-trash'></i>
              <span>Delete</span>
            </button>
            <input type='checkbox' class='toggle'></input>
            <!-- The loading indicator is shown during file processing -->
	          <span class='fileupload-loading'></span>
          </div>
          <!-- The global progress information -->
          <div class='col-lg-5 fileupload-progress fade'>
            <!-- The global progress bar -->
            <div class='progress progress-striped active' role='progressbar' aria-valuemin='0' aria-valuemax='100'>
              <div class='progress-bar progress-bar-success' style='width: 0%;'></div>
            </div>
            <!-- The extended global progress information -->
            <div class='progress-extended'>&nbsp;</div>
          </div>
        </div>
        <!-- The table listing the files available for upload/download -->
        <table role='presentation' class='table table-striped' id='upload_files'>
          <tbody class='files'></tbody>
        </table>".html_safe + (block ? capture(&block) : '')
      end
    end
302018
public function renderCaptchaHTML()
    {
        $html = '<div id="_g-recaptcha"></div>' . PHP_EOL;
        if ($this->getOption('hideBadge', false)) {
            $html .= '<style>.grecaptcha-badge{display:none;!important}</style>' . PHP_EOL;
        }

        $html .= '<div class="g-recaptcha" data-sitekey="' . $this->siteKey .'" ';
        $html .= 'data-size="invisible" data-callback="_submitForm" data-badge="' . $this->getOption('dataBadge', 'bottomright') . '"></div>';
        return $html;
    }
922227
public function displayCaptchaPicture()
    {
        $app = Application::getFacadeApplication();
        $responseFactory = $app->make(ResponseFactoryInterface::class);

        return $responseFactory->notFound('Captcha without image');
    }
929812
public static function input_hidden_params(moodle_url $url, array $exclude = null) {
        $exclude = (array)$exclude;
        $params = $url->params();
        foreach ($exclude as $key) {
            unset($params[$key]);
        }

        $output = '';
        foreach ($params as $key => $value) {
            $attributes = array('type'=>'hidden', 'name'=>$key, 'value'=>$value);
            $output .= self::empty_tag('input', $attributes)."\n";
        }
        return $output;
    }