function lambda_translate_meta($content) { if (function_exists('qtrans_useCurrentLanguageIfNotFoundShowAvailable')) { $content = qtrans_useCurrentLanguageIfNotFoundShowAvailable($content); } return $content; }
function lambda_translate_meta($content) { #----------------------------------------------------------------- # Applies a special filer depending on the used plugin #----------------------------------------------------------------- $content = qtrans_useCurrentLanguageIfNotFoundShowAvailable($content); return $content; }
/** * srp_sanitize() * * This method sanitizes strings output. * * @author Luca Grandicelli <*****@*****.**> * @copyright (C) 2011-2014 Luca Grandicelli * @package special-recent-posts-free * @version 2.0.4 * @access private * @param string $string The string to sanitize. * @return string It returns a sanitized string. */ private function srp_sanitize($string) { // Checking for External Shortcodes Compatibility option. // If it's enabled, let's not remove any shortcode found within the post content. if ('no' == $this->widget_args['ext_shortcodes_compatibility']) { $string = strip_shortcodes($string); } // We need to remove all the exceeding stuff. Removing shortcodes and slashes. $temp_output = trim(stripslashes($string)); // Checking for the qTranslate filter. if (function_exists('qtrans_useCurrentLanguageIfNotFoundShowAvailable')) { // Applying qTranslate Filter if this exists. $temp_output = qtrans_useCurrentLanguageIfNotFoundShowAvailable($temp_output); } // If "allowed_tags" option is on, keep them separated from strip_tags. if (!empty($this->widget_args['allowed_tags'])) { // Handling the <br /> tag. $this->widget_args['allowed_tags'] = str_replace('<br />', '<br>', $this->widget_args['allowed_tags']); // Stripping tags except the ones specified. return strip_tags($temp_output, htmlspecialchars_decode($this->widget_args['allowed_tags'])); } else { // Otherwise completely strip tags from text. return strip_tags($temp_output); } }
/** * @since 4.3 * * @param $content * * @return string */ public function filterPostContent($content) { return qtrans_useCurrentLanguageIfNotFoundShowAvailable($content); }
function qtrans_postsFilter($posts) { if (is_array($posts)) { foreach ($posts as $post) { $post->post_content = qtrans_useCurrentLanguageIfNotFoundShowAvailable($post->post_content); $post = qtrans_useCurrentLanguageIfNotFoundUseDefaultLanguage($post); } } return $posts; }
/** * Show the correct language on the [downloads] short code if qTranslate is active * * @since 1.7 * @param string $content Download content * @return string $content Download content */ function edd_qtranslate_content($content) { if (defined('QT_LANGUAGE')) { $content = qtrans_useCurrentLanguageIfNotFoundShowAvailable($content); } return $content; }
private function srp_sanitize($string) { // We need to remove all the exceeding stuff. Removing shortcodes and slashes. $temp_output = trim(stripslashes(strip_shortcodes($string))); // Applying qTranslate Filter if this exists. if (function_exists('qtrans_useCurrentLanguageIfNotFoundShowAvailable')) { $temp_output = qtrans_useCurrentLanguageIfNotFoundShowAvailable($temp_output); } // If "allowed_tags" option is on, keep them separated from strip_tags. if (!empty($this->widget_args["allowed_tags"])) { // Handling the <br /> tag. $this->widget_args["allowed_tags"] = str_replace('<br />', '<br>', $this->widget_args["allowed_tags"]); // Stripping tags except the ones specified. return strip_tags($temp_output, htmlspecialchars_decode($this->widget_args["allowed_tags"])); } else { // Otherwise completely strip tags from text. return strip_tags($temp_output); } }
$helper = new Spu_Helper(); // has box with this id been found? if (!$box instanceof WP_Post || $box->post_status !== 'publish') { return; } $opts = $helper->get_box_options($box->ID); $css = $opts['css']; $content = $box->post_content; $data_attrs = ''; $box_class = ''; $width = !empty($css['width']) ? $css['width'] : ''; // run filters on content $content = apply_filters('spu/popup/content', $content, $box); // Qtranslate support if (function_exists('qtrans_useCurrentLanguageIfNotFoundShowAvailable')) { $content = qtrans_useCurrentLanguageIfNotFoundShowAvailable($content); } // WPGlobus support if (class_exists('WPGlobus')) { $content = WPGlobus_Core::text_filter($content, WPGlobus::Config()->language); } do_action('spu/popup/before_popup', $box, $opts, $css); ?> <style type="text/css"> #spu-<?php echo $box->ID; ?> { background-color: <?php echo !empty($css['background_color']) ? esc_attr($css['background_color']) : 'white'; ?>
function yiw_translate($string) { if (!function_exists('qtrans_useCurrentLanguageIfNotFoundShowAvailable')) { return $string; } $string = preg_replace('/\\[([a-z]{2})\\]/', '<!--:$1-->', $string); $string = preg_replace('/\\[\\/([a-z]{2})\\]/', '<!--:-->', $string); $string = qtrans_useCurrentLanguageIfNotFoundShowAvailable($string); return $string; }
function ut_translate_meta($content) { if (function_exists('qtrans_useCurrentLanguageIfNotFoundShowAvailable')) { return qtrans_useCurrentLanguageIfNotFoundShowAvailable($content); } if (function_exists('ppqtrans_useCurrentLanguageIfNotFoundShowAvailable')) { return ppqtrans_useCurrentLanguageIfNotFoundShowAvailable($content); } if (function_exists('qtranxf_useCurrentLanguageIfNotFoundShowAvailable')) { return qtranxf_useCurrentLanguageIfNotFoundShowAvailable($content); } return $content; }