HEX
Server: Apache/2.4.65 (Debian)
System: Linux web6 5.10.0-36-amd64 #1 SMP Debian 5.10.244-1 (2025-09-29) x86_64
User: innocamp (1028)
PHP: 7.4.33
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: //home/plan4ev/public_html/wp-content/plugins/caldera-forms/classes/sync/html.php
<?php
/**
 * Magic tag sync implementation for HTML fields
 *
 * @package Caldera_Forms
 * @author    Josh Pollock <Josh@CalderaWP.com>
 * @license   GPL-2.0+
 * @link
 * @copyright 2016 CalderaWP LLC
 */
class Caldera_Forms_Sync_HTML  extends Caldera_Forms_Sync_Sync {

	/**
	 * Bind field list as field data-field attrs
	 *
	 * @since 1.5.0
	 *
	 * @var array
	 */
	protected $attr_binds;

	/**
	 * Quoted bind field list
	 *
	 * @since 1.5.0
	 *
	 * @var array
	 */
	protected $bind_fields;

	/**
	 * Prefix for template and content ID attributes
	 *
	 * @since 1.5.0
	 *
	 * @var string
	 */
	protected $template_prefix = 'html-content-';

	/**
	 * Get the date-field formatted binds
	 *
	 * @since 1.5.0
	 *
	 * @return array
	 */
	public function get_attr_binds(){
		if ( is_array( $this->attr_binds ) ) {
			return $this->attr_binds;
		} else {
			return array();
		}
	}

	/**
	 * Get ID of the template
	 *
	 * @since 1.5.0
	 *
	 * @return string
	 */
	public function template_id(){
		return $this->template_prefix . $this->field_base_id . '-tmpl';
	}

	/**
	 * Get ID of the content attribute
	 *
	 * @since 1.5.0
	 *
	 * @return string
	 */
	public function content_id(){
		return $this->template_prefix . $this->field_base_id;
	}

	/**
	 * Get the quoted binds list
	 *
	 * @since 1.5.0
	 *
	 * @return array
	 */
	public function get_bind_fields(){
		if( is_array( $this->bind_fields ) ){
			return $this->bind_fields;
		}else{
			return array();
		}
	}

	/**
	 * @inheritdoc
	 * @since 1.5.0
	 */
	protected function add_bind( $key_id ) {
		$this->binds[] = $key_id;
		$type = Caldera_Forms_Field_Util::get_type( $key_id, $this->form );
		if( 'calculation' == $type ){
			$this->attr_binds[] = '[data-calc-field="'.$key_id . '_' . $this->current_form_count.'"]';

		}else{
			$this->attr_binds[] = '[data-field="'.$key_id.'"]';
		}

		$this->bind_fields[] = '"'.$key_id.'"';
	}




}