| Server IP : 216.250.13.251 / Your IP : 216.73.216.164 Web Server : nginx/1.24.0 System : Linux gunay 6.8.0-134-generic #134-Ubuntu SMP PREEMPT_DYNAMIC Fri Jun 26 18:43:11 UTC 2026 x86_64 User : root ( 0) PHP Version : 7.4.33 Disable Function : 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, MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /var/www/gunay/wp-content/plugins/js_composer/include/params/textarea_html/ |
Upload File : |
<?php
if ( ! defined( 'ABSPATH' ) ) {
die( '-1' );
}
global $vc_html_editor_already_is_use;
$vc_html_editor_already_is_use = false;
/**
* @param $settings
* @param $value
*
* @return string
* @since 4.2
*/
function vc_textarea_html_form_field( $settings, $value ) {
global $vc_html_editor_already_is_use;
$output = '';
if ( false !== $vc_html_editor_already_is_use ) {
$output .= '<textarea name="' . esc_attr( $settings['param_name'] ) . '" class="wpb_vc_param_value wpb-textarea ' . esc_attr( $settings['param_name'] ) . ' textarea">' . $value . '</textarea>';
$output .= '<div class="updated"><p>' . sprintf( esc_html__( 'Field type is changed from "textarea_html" to "textarea", because it is already used by %s field. Textarea_html field\'s type can be used only once per shortcode.', 'js_composer' ), $vc_html_editor_already_is_use ) . '</p></div>';
} elseif ( function_exists( 'wp_editor' ) ) {
$default_content = $value;
// WP 3.3+
ob_start();
wp_editor( '', 'wpb_tinymce_' . esc_attr( $settings['param_name'] ), array(
'editor_class' => 'wpb-textarea visual_composer_tinymce ' . esc_attr( $settings['param_name'] . ' ' . $settings['type'] ),
'media_buttons' => true,
'wpautop' => false,
) );
$output_value = ob_get_contents();
ob_end_clean();
$output .= $output_value . '<input type="hidden" name="' . esc_attr( $settings['param_name'] ) . '" class="vc_textarea_html_content wpb_vc_param_value ' . esc_attr( $settings['param_name'] ) . '" value="' . htmlspecialchars( $default_content ) . '"/>';
$vc_html_editor_already_is_use = $settings['param_name'];
}
return $output;
}