• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP ts_escape函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中ts_escape函数的典型用法代码示例。如果您正苦于以下问题:PHP ts_escape函数的具体用法?PHP ts_escape怎么用?PHP ts_escape使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了ts_escape函数的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: tag_escape

        }
        ?>
</<?php 
        echo tag_escape($title_tag);
        ?>
>
                                <?php 
        echo trim($ts_caption) ? '<p class="title-bar-caption">' . wp_kses_post($ts_caption) . '</p>' : '';
    }
    ?>
                            </div>
                            <div class="span4 breadcrumbs-wrap">
                                <?php 
    $has_yoast_breadcrumbs = false;
    if (function_exists('yoast_breadcrumb')) {
        $yoast_breadcrumbs = yoast_breadcrumb('<div class="breadcrumbs small" data-breadcrumbs-by="yoast">', '</div>', false);
        $has_yoast_breadcrumbs = trim($yoast_breadcrumbs) ? true : false;
    }
    if (!$has_yoast_breadcrumbs) {
        echo dimox_breadcrumbs();
    } else {
        echo ts_escape($yoast_breadcrumbs);
    }
    ?>
                            </div>
                        </div>
                    </div>
                </div>                
            </div>
<?php 
}
开发者ID:sekane81,项目名称:ratoninquietoweb,代码行数:31,代码来源:title-page.php


示例2: while

            <?php 
if (have_posts()) {
    while (have_posts()) {
        the_post();
        ?>
                <div id="main-container" class="container clearfix">
                    <div id="main" class="<?php 
        echo esc_attr(ts_main_div_class());
        ?>
 clearfix">
                        <div class="entry single-entry clearfix">
                            <?php 
        if (ts_option_vs_default('show_images_on_post', 1) == 1) {
            $featured_media_vars = array('media_width' => $crop_width, 'media_height' => $crop_height, 'allow_audio' => 1, 'allow_self_hosted_video' => 1, 'is_single' => 1);
            $featured_media = ts_get_featured_media($featured_media_vars);
            echo trim($featured_media) ? '<div id="ts-post-featured-media-wrap">' . ts_escape($featured_media) . '</div>' : '';
        }
        ?>
                            
                            <div id="ts-post-content-sidebar-wrap" class="clearfix">
                                <div id="ts-post-wrap">
                                    
                                    <div id="ts-post" <?php 
        post_class('post ts-post-section clearfix');
        ?>
>
                                        
                                        
                                        <div id="ts-post-the-content-wrap">
                                            
                                            <div id="ts-post-comments-share-wrap" class="clearfix">
开发者ID:estvmachine,项目名称:nicowp,代码行数:31,代码来源:single.php


示例3: get_category_link

                                    <a href="<?php 
        echo get_category_link($category[0]['term_id']);
        ?>
"><strong><?php 
        echo esc_html($category[0]['name']);
        ?>
</strong></a>
                                </div>
                                <div class="ts-meta-wrap <?php 
        echo $ts_show->media && trim($media) ? 'media-meta-wrap' : 'meta-wrap';
        ?>
">
                                    <?php 
        if ($ts_show->media && trim($media)) {
            $allow_gals = isset($atts['allow_galleries']) ? $atts['allow_galleries'] : '';
            echo ts_escape($media);
        }
        if ($ts_show->meta) {
            if ($post_type == 'portfolio') {
                ?>
                                    <div class="entry-info portfolio-entry-info"><p class="small-size <?php 
                echo esc_attr($text_align);
                ?>
"><?php 
                echo ts_get_the_category('portfolio-category', 'text');
                ?>
</p></div>
                                    <?php 
            } elseif ($post_type == 'page') {
                ?>
                                    <div class="entry-info page-entry-info"><p class="small-size <?php 
开发者ID:estvmachine,项目名称:nicowp,代码行数:31,代码来源:loop.php


示例4: _e

?>

	<?php 
if ($product->is_type(array('simple', 'variable')) && get_option('woocommerce_enable_sku') == 'yes' && $product->get_sku()) {
    ?>
		<span itemprop="productID" class="sku_wrapper"><?php 
    _e('SKU:', 'woocommerce');
    ?>
 <span class="sku"><?php 
    echo ts_escape($product->get_sku());
    ?>
</span>.</span>
	<?php 
}
?>

	<?php 
$size = sizeof(get_the_terms($post->ID, 'product_cat'));
echo ts_escape($product->get_categories(', ', '<span class="posted_in">' . _n('Category:', 'Categories:', $size, 'woocommerce') . ' ', '.</span>'));
?>

	<?php 
$size = sizeof(get_the_terms($post->ID, 'product_tag'));
echo ts_escape($product->get_tags(', ', '<span class="tagged_as">' . _n('Tag:', 'Tags:', $size, 'woocommerce') . ' ', '.</span>'));
?>

	<?php 
do_action('woocommerce_product_meta_end');
?>

</div>
开发者ID:dqishmirian,项目名称:jrrny,代码行数:31,代码来源:meta.php


示例5: ts_escape

 *
 * @author 		WooThemes
 * @package 	WooCommerce/Templates
 * @version     1.6.4
 */
if (!defined('ABSPATH')) {
    exit;
}
// Exit if accessed directly
global $post, $product;
if (ts_option_vs_default('show_shop_prices_on_single', 1) != 1) {
    return false;
}
?>
<div itemprop="offers" itemscope itemtype="http://schema.org/Offer">

	<p itemprop="price" class="price"><?php 
echo ts_escape($product->get_price_html());
?>
</p>

	<meta itemprop="priceCurrency" content="<?php 
echo ts_escape(get_woocommerce_currency());
?>
" />
	<link itemprop="availability" href="http://schema.org/<?php 
echo $product->is_in_stock() ? 'InStock' : 'OutOfStock';
?>
" />

</div>
开发者ID:dqishmirian,项目名称:jrrny,代码行数:31,代码来源:price.php


示例6: do_action

    do_action('woocommerce_before_add_to_cart_button');
    ?>

		<div class="single_variation_wrap" style="display:none;">
			<?php 
    do_action('woocommerce_before_single_variation');
    ?>

			<div class="single_variation"></div>

			<div class="variations_button">
				<?php 
    woocommerce_quantity_input();
    ?>
				<button type="submit" class="single_add_to_cart_button button alt"><?php 
    echo ts_escape($product->single_add_to_cart_text());
    ?>
</button>
			</div>

			<input type="hidden" name="add-to-cart" value="<?php 
    echo esc_attr($product->id);
    ?>
" />
			<input type="hidden" name="product_id" value="<?php 
    echo esc_attr($post->ID);
    ?>
" />
			<input type="hidden" name="variation_id" value="" />

			<?php 
开发者ID:dqishmirian,项目名称:jrrny,代码行数:31,代码来源:variable.php


示例7: _e

		<?php 
    if ($product->has_dimensions()) {
        $has_row = true;
        ?>
			<tr class="<?php 
        if (($alt = $alt * -1) == 1) {
            echo 'alt';
        }
        ?>
">
				<th><?php 
        _e('Dimensions', 'woocommerce');
        ?>
</th>
				<td class="product_dimensions"><?php 
        echo ts_escape($product->get_dimensions());
        ?>
</td>
			</tr>
		<?php 
    }
    ?>

	<?php 
}
?>

	<?php 
foreach ($attributes as $attribute) {
    if (empty($attribute['is_visible']) || $attribute['is_taxonomy'] && !taxonomy_exists($attribute['name'])) {
        continue;
开发者ID:dqishmirian,项目名称:jrrny,代码行数:31,代码来源:product-attributes.php


示例8: esc_attr

         }
         echo '<div class="fluid-width-video-wrapper"><div>';
         echo '<iframe id="' . esc_attr($video_service . '-' . $slider->post->ID . '-' . $rand_id) . '" src="' . esc_url($video_src) . '" width="' . absint($w) . '" ' . $img_height . ' data-videoid="' . esc_attr($video_id) . '" class="' . esc_attr($iframe_class) . '" allowFullScreen webkitAllowFullScreen></iframe>';
         echo '</div></div>' . "\n";
     }
     if ($img) {
         echo strip_tags($link_begin, '<a>');
         echo $ts_slider_type == 'flex' && $slider_width_class == 'full' ? '' : strip_tags($img_html, '<a><img>');
         if ((trim($title) || trim($descr)) && $hide_text != '1') {
             echo '<div class="ts-item-details">' . "\n";
             echo $ts_slider_type == 'flex' && $w == 1360 ? '<div class="ts-item-details-inner container">' . "\n" : '<div class="ts-item-details-inner">' . "\n";
             if ($ts_slider_source == 'portfolio') {
                 echo '<h' . absint($title_size) . ' class="portfolio-title title text-' . esc_attr($slider_text_align) . ' color-white">' . ts_escape($title) . '</h' . absint($title_size) . '>' . "\n";
                 echo trim($meta) ? '<p class="portfolio-meta color-shortcode white text-' . esc_attr($slider_text_align) . '">' . strip_tags($meta, '<span>') . '</p>' . "\n" : '';
             } else {
                 echo '<h' . absint($title_size) . ' class="blog-title title text-' . esc_attr($slider_text_align) . ' color-white">' . ts_sticky_badge() . ts_escape($title) . '</h' . absint($title_size) . '>' . "\n";
                 echo '<p class="blog-meta text-' . esc_attr($slider_text_align) . '">' . strip_tags($meta, '<span>') . '</p>' . "\n";
             }
             echo '</div></div>' . "\n";
         }
         echo strip_tags($link_end, '<a>');
     }
     echo '</li>' . "\n";
 }
 echo '</ul>' . "\n";
 echo '<span class="pause-slider smaller uppercase bg-primary"><i class="fa fa-pause"></i> ' . __('Pause', 'ThemeStockyard') . '</span>' . "\n";
 echo '<span class="play-slider smaller uppercase bg-primary"><i class="fa fa-play"></i> ' . __('Resume', 'ThemeStockyard') . '</span>' . "\n";
 echo '</div>' . "\n";
 echo '<div class="ts-main-flex-nav"></div>' . "\n";
 echo '</div>' . "\n";
 echo '</div>' . "\n";
开发者ID:dqishmirian,项目名称:jrrny,代码行数:31,代码来源:carousel-flex-slider.php


示例9: ts_escape

<?php

/**
 * Loop Price
 *
 * @author 		WooThemes
 * @package 	WooCommerce/Templates
 * @version     1.6.4
 */
if (!defined('ABSPATH')) {
    exit;
}
// Exit if accessed directly
global $product;
if (ts_option_vs_default('show_shop_prices_on_results', 1) != 1) {
    return;
}
?>

<?php 
if ($price_html = $product->get_price_html()) {
    ?>
	<span class="price"><?php 
    echo ts_escape($price_html);
    ?>
</span>
<?php 
}
开发者ID:sekane81,项目名称:ratoninquietoweb,代码行数:28,代码来源:price.php


示例10: ts_escape

<?php

/**
 * Loop Rating
 *
 * @author 		WooThemes
 * @package 	WooCommerce/Templates
 * @version     2.0.0
 */
if (!defined('ABSPATH')) {
    exit;
}
// Exit if accessed directly
global $product;
if (get_option('woocommerce_enable_review_rating') == 'no' || ts_option_vs_default('show_shop_reviews_on_results', 1) != 1) {
    return;
}
?>

<?php 
if ($rating_html = $product->get_rating_html()) {
    ?>
	<?php 
    echo ts_escape($rating_html);
}
开发者ID:dqishmirian,项目名称:jrrny,代码行数:25,代码来源:rating.php



注:本文中的ts_escape函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP ts_essentials_escape函数代码示例发布时间:2022-05-23
下一篇:
PHP ts_cache函数代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap