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

PHP et_new_thumb_resize函数代码示例

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

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



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

示例1: insertThumbnailRSS

function insertThumbnailRSS($content)
{
    global $post;
    $thumb = '';
    $thumb = get_post_meta($post->ID, 'Thumbnail', true);
    if (has_post_thumbnail($post->ID)) {
        $content = '<p>' . get_the_post_thumbnail($post->ID, 'medium') . '</p>' . $content;
    } else {
        if ($thumb != '') {
            $content = '<p>' . '<img src="' . et_new_thumb_resize(et_multisite_thumbnail($thumb), 300, 200, '', true) . '"/>' . '</p>' . $content;
        }
    }
    return $content;
}
开发者ID:douglaswebdesigns,项目名称:ask-bio-expert,代码行数:14,代码来源:functions.php


示例2: widget

    function widget($args, $instance)
    {
        extract($args);
        $logoImagePath = empty($instance['logoImagePath']) ? '' : esc_url($instance['logoImagePath']);
        $copyrightInfo = empty($instance['copyrightInfo']) ? '' : esc_attr($instance['copyrightInfo']);
        $imagePath = empty($instance['imagePath']) ? '' : esc_url($instance['imagePath']);
        $textInfo = empty($instance['textInfo']) ? '' : esc_attr($instance['textInfo']);
        $readMoreUrl = empty($instance['readMoreUrl']) ? '' : esc_url($instance['readMoreUrl']);
        $readMoreText = empty($instance['readMoreText']) ? '' : esc_attr($instance['readMoreText']);
        echo $before_widget;
        ?>
	
<p id="footer-logo"><img alt="" src="<?php 
        echo $logoImagePath;
        ?>
" /><span><?php 
        echo $copyrightInfo;
        ?>
</span></p>
<div class="thumb">
	<img class="item-image" alt="" src="<?php 
        echo et_new_thumb_resize(et_multisite_thumbnail($imagePath), 56, 56, '', true);
        ?>
" />
	<span class="overlay"></span>
</div>
<p><?php 
        echo $textInfo;
        ?>
</p>
<a class="readmore" href="<?php 
        echo $readMoreUrl;
        ?>
"><span><?php 
        echo $readMoreText;
        ?>
</span></a>

<?php 
        echo $after_widget;
    }
开发者ID:nxtclass,项目名称:NXTClass-themes,代码行数:41,代码来源:widget-customlogo.php


示例3: widget

    function widget($args, $instance)
    {
        extract($args);
        $title = apply_filters('widget_title', empty($instance['title']) ? 'About Me' : esc_html($instance['title']));
        $imagePath = empty($instance['imagePath']) ? '' : esc_url($instance['imagePath']);
        $aboutText = empty($instance['aboutText']) ? '' : $instance['aboutText'];
        echo $before_widget;
        if ($title) {
            echo $before_title . $title . $after_title;
        }
        ?>
		<div class="clearfix">
			<img src="<?php 
        echo et_new_thumb_resize(et_multisite_thumbnail($imagePath), 74, 74, '', true);
        ?>
" id="about-image" alt="" />
			<?php 
        echo wp_kses_post($aboutText);
        ?>
		</div> <!-- end about me section -->
	<?php 
        echo $after_widget;
    }
开发者ID:damiansu,项目名称:wordpress-es,代码行数:23,代码来源:widget-about.php


示例4: get_post_meta

</h1>

	<?php 
        $media = get_post_meta($post->ID, '_et_used_images', true);
        $width = apply_filters('et_single_project_width', 960);
        $height = apply_filters('et_single_project_height', 480);
        $titletext = get_the_title();
        if ($media) {
            echo '<div class="flexslider"><ul class="slides">';
            foreach ((array) $media as $et_media) {
                echo '<li class="slide">';
                if (is_numeric($et_media)) {
                    $et_fullimage_array = wp_get_attachment_image_src($et_media, 'full');
                    if ($et_fullimage_array) {
                        $et_fullimage = $et_fullimage_array[0];
                        echo '<img src="' . esc_url(et_new_thumb_resize(et_multisite_thumbnail($et_fullimage), $width, $height, '', true)) . '" width="' . esc_attr($width) . '" height="' . esc_attr($height) . '" alt="' . esc_attr($titletext) . '" />';
                    }
                } else {
                    $video_embed = $wp_embed->shortcode('', esc_url($et_media));
                    $video_embed = preg_replace('/<embed /', '<embed wmode="transparent" ', $video_embed);
                    $video_embed = preg_replace('/<\\/object>/', '<param name="wmode" value="transparent" /></object>', $video_embed);
                    $video_embed = preg_replace("/height=\"[0-9]*\"/", "height={$height}", $video_embed);
                    $video_embed = preg_replace("/width=\"[0-9]*\"/", "width={$width}", $video_embed);
                    echo $video_embed;
                }
                echo '</li>';
            }
            echo '</ul></div>';
        } else {
            $thumb = '';
            $classtext = 'single_project_image';
开发者ID:AttyC,项目名称:elizafilby,代码行数:31,代码来源:single-project.php


示例5: et_show_ajax_project

function et_show_ajax_project()
{
    global $wp_embed;
    $project_id = (int) $_POST['et_project_id'];
    $portfolio_args = array('post_type' => 'project', 'p' => $project_id);
    $portfolio_query = new WP_Query(apply_filters('et_ajax_portfolio_args', $portfolio_args));
    while ($portfolio_query->have_posts()) {
        $portfolio_query->the_post();
        global $post;
        $width = (int) apply_filters('et_ajax_media_width', 600);
        $height = (int) apply_filters('et_ajax_media_height', 480);
        $titletext = get_the_title();
        $media = get_post_meta(get_the_ID(), '_et_used_images', true);
        echo '<div class="et_media">';
        if ($media) {
            echo '<div class="flexslider"><ul class="slides">';
            foreach ((array) $media as $et_media) {
                echo '<li class="slide">';
                if (is_numeric($et_media)) {
                    $et_fullimage_array = wp_get_attachment_image_src($et_media, 'full');
                    if ($et_fullimage_array) {
                        $et_fullimage = $et_fullimage_array[0];
                        echo '<img src="' . esc_attr(et_new_thumb_resize(et_multisite_thumbnail($et_fullimage), $width, $height, '', true)) . '" width="' . esc_attr($width) . '" height="' . esc_attr($height) . '" alt="' . esc_attr($titletext) . '" />';
                    }
                } else {
                    $video_embed = apply_filters('the_content', $wp_embed->shortcode('', esc_url($et_media)));
                    $video_embed = preg_replace('/<embed /', '<embed wmode="transparent" ', $video_embed);
                    $video_embed = preg_replace('/<\\/object>/', '<param name="wmode" value="transparent" /></object>', $video_embed);
                    $video_embed = preg_replace("/height=\"[0-9]*\"/", "height={$height}", $video_embed);
                    $video_embed = preg_replace("/width=\"[0-9]*\"/", "width={$width}", $video_embed);
                    echo $video_embed;
                }
                echo '</li>';
            }
            echo '</ul></div>';
        } else {
            $thumb = '';
            $classtext = '';
            $titletext = get_the_title();
            $thumbnail = get_thumbnail($width, $height, $classtext, $titletext, $titletext, false, 'Ajaximage');
            $thumb = $thumbnail["thumb"];
            echo '<a href="' . esc_url(get_permalink()) . '">';
            print_thumbnail($thumb, $thumbnail["use_timthumb"], $titletext, $width, $height, $classtext);
            echo '</a>';
        }
        echo '</div> <!-- end .et_media -->';
        echo '<div class="et_media_description">' . '<h2 class="title">' . '<a href="' . get_permalink() . '">' . get_the_title() . '</a>' . '</h2>' . truncate_post(560, false);
        echo '</div> <!-- end .et_media_description -->';
        echo '<a class="more" href="' . get_permalink() . '">' . __('More info &raquo;', 'Flexible') . '</a>';
    }
    wp_reset_postdata();
    die;
}
开发者ID:AttyC,项目名称:elizafilby,代码行数:53,代码来源:functions.php


示例6: et_testimonial

function et_testimonial($atts, $content = null)
{
    extract(shortcode_atts(array('style' => '', 'id' => '', 'class' => '', 'author' => '', 'company' => '', 'image' => '', 'timthumb' => 'on'), $atts, 'testimonial'));
    $content = et_content_helper($content);
    $style = $style != '' ? ' style="' . esc_attr($style) . '"' : '';
    $id = $id != '' ? " id='" . esc_attr($id) . "'" : '';
    $class = $class != '' ? esc_attr(' ' . $class) : '';
    $orig_name = $author;
    $author = $author != '' ? "<span class='t-author'>" . esc_html($author) . "</span>" : '';
    $company = $company != '' ? "<span class='t-position'>" . esc_html($company) . "</span>" : '';
    $image_markup = '';
    if ($image != '') {
        $image = $timthumb == 'on' ? et_new_thumb_resize($image, 60, 60, '', $forstyle = true) : $image;
        $image_markup = "\n\t\t\t<div class='t-img'>\n\t\t\t\t<img src='" . esc_attr($image) . "' alt='" . esc_attr($orig_name) . "' />\n\t\t\t\t<span class='t-overlay'></span>\n\t\t\t</div>\n\t\t";
    }
    $output = "\n\t\t<div{$id} class='et-testimonial-box{$class}'{$style}>\n\t\t\t<div class='et-testimonial-author-info clearfix'>\n\t\t\t\t{$image_markup}\n\t\t\t\t{$author}\n\t\t\t\t{$company}\n\t\t\t</div>\n\n\t\t\t<div class='et-testimonial clearfix'>\n\t\t\t\t{$content}\n\t\t\t</div>\n\n\t\t    <div class='t-bottom-arrow'></div>\n\t\t</div>";
    return $output;
}
开发者ID:amon-ra,项目名称:divi,代码行数:18,代码来源:shortcodes.php


示例7: et_testimonial

function et_testimonial($atts, $content = null)
{
    $args = shortcode_atts(array('style' => '', 'id' => '', 'class' => '', 'author' => '', 'company' => '', 'image' => '', 'timthumb' => 'on'), $atts, 'testimonial');
    $content = et_content_helper($content);
    $args['style'] = $args['style'] != '' ? ' style="' . esc_attr($args['style']) . '"' : '';
    $args['id'] = $args['id'] != '' ? " id='" . esc_attr($args['id']) . "'" : '';
    $args['class'] = $args['class'] != '' ? esc_attr(' ' . $args['class']) : '';
    $orig_name = $args['author'];
    $args['author'] = $args['author'] != '' ? "<span class='t-author'>" . esc_html($args['author']) . "</span>" : '';
    $args['company'] = $args['company'] != '' ? "<span class='t-position'>" . esc_html($args['company']) . "</span>" : '';
    $image_markup = '';
    if ($args['image'] != '') {
        $args['image'] = $args['timthumb'] == 'on' ? et_new_thumb_resize($args['image'], 60, 60, '', $forstyle = true) : $args['image'];
        $image_markup = "\n\t\t\t<div class='t-img'>\n\t\t\t\t<img src='" . esc_attr($args['image']) . "' alt='" . esc_attr($orig_name) . "' />\n\t\t\t\t<span class='t-overlay'></span>\n\t\t\t</div>\n\t\t";
    }
    $output = "\n\t\t<div{$args['id']} class='et-testimonial-box{$args['class']}'{$args['style']}>\n\t\t\t<div class='et-testimonial-author-info clearfix'>\n\t\t\t\t{$image_markup}\n\t\t\t\t{$args['author']}\n\t\t\t\t{$args['company']}\n\t\t\t</div>\n\n\t\t\t<div class='et-testimonial clearfix'>\n\t\t\t\t{$content}\n\t\t\t</div>\n\n\t\t    <div class='t-bottom-arrow'></div>\n\t\t</div>";
    return $output;
}
开发者ID:rthburke,项目名称:fltHub,代码行数:18,代码来源:shortcodes.php


示例8: get_post_meta

}
if (is_page()) {
    $et_used_images = get_post_meta(get_the_ID(), '_et_used_images', true);
}
if ('' != $bg_image || $et_used_images) {
    if ('' != $bg_image) {
        echo '<li>
								<img src="' . esc_attr($bg_image) . '" alt="" />
							</li>';
    } else {
        foreach ($et_used_images as $et_attachment_id => $et_used_image) {
            $et_fullimage_array = wp_get_attachment_image_src($et_attachment_id, 'full');
            if ($et_fullimage_array) {
                $et_fullimage = $et_fullimage_array[0];
                echo '<li>
										<img src="' . esc_attr($et_fullimage) . '" data-smallimage="' . esc_attr(et_new_thumb_resize(et_multisite_thumbnail($et_fullimage), 43, 43, '', true)) . '" data-image_title="' . esc_attr($et_used_image['image_title']) . '" data-image_desc="' . esc_attr($et_used_image['image_description']) . '" alt="" />
									</li>';
            }
        }
    }
}
echo '</ul>';
?>

		<div id="pattern_overlay"></div>

		<?php 
wp_footer();
?>
	</div> <!-- #wrapper -->
</body>
开发者ID:iinspiration,项目名称:theme,代码行数:31,代码来源:footer.php


示例9: et_new_thumb_resize

        for ($i = 0; $i <= count($custom["thumbs"]) - 1; $i++) {
            ?>
					<a href="#" <?php 
            if ($i == 0) {
                echo 'class="active"';
            }
            if ($i == count($custom["thumbs"]) - 1) {
                echo 'class="last"';
            }
            ?>
 rel="<?php 
            echo $i + 1;
            ?>
">
						<?php 
            echo et_new_thumb_resize(et_multisite_thumbnail($custom["thumbs"][$i]), 69, 69);
            ?>
						<span class="overlay"></span>
					</a>
				<?php 
        }
        ?>
			</div> <!-- #product-thumbs -->
		<?php 
    }
    ?>
	</div> <!-- #product-slider -->
<?php 
}
?>
开发者ID:nimishavyas,项目名称:proiti,代码行数:30,代码来源:single-product.php


示例10: et_new_lb_image

function et_new_lb_image($atts, $content = null)
{
    extract(shortcode_atts(array('image_url' => '', 'imagesize' => '', 'image_title' => '', 'image_alt' => ''), $atts));
    $attributes = et_lb_get_attributes($atts, "et_lb_image");
    if ('' != $imagesize) {
        $image_size = explode('x', $imagesize);
        $image_size = array_map('intval', $image_size);
    }
    $image = '' != $image_url && '' == $imagesize ? $image_url : et_new_thumb_resize(et_multisite_thumbnail($image_url), $image_size[0], $image_size[1], '', true);
    if ('' != $image) {
        $image = sprintf('<img alt="%1$s" src="%2$s" title="%3$s" />', esc_attr($image_alt), esc_attr($image), esc_attr($image_title));
    }
    $output = "<div {$attributes['class']}{$attributes['inline_styles']}>\n\t\t\t\t\t<div class='et_lb_module_content'>\n\t\t\t\t\t\t<div class='et_lb_module_content_inner clearfix'>" . ('' != $image ? '<div class="et_lb_image_box">' . "<a href='" . esc_url($image_url) . "' class='fancybox' title='" . esc_attr($image_title) . "'>{$image}<span class='et_lb_zoom_icon'></span></a>" . '</div>' : '') . ('' != trim($content) ? '<div class="et_lb_image_content">' . do_shortcode(et_lb_fix_shortcodes($content)) . '</div> <!-- end .et_lb_image_content -->' : '') . "\t\t</div> <!-- end .et_lb_module_content_inner -->\n\t\t\t\t\t</div> <!-- end .et_lb_module_content -->\n\t\t\t\t</div> <!-- end .et_lb_widget_area -->";
    et_new_load_convertible_scripts(array('image'));
    return $output;
}
开发者ID:iinspiration,项目名称:theme,代码行数:16,代码来源:et-layout-builder.php


示例11: et_testimonial

function et_testimonial($atts, $content = null)
{
    extract(shortcode_atts(array('style' => '', 'id' => '', 'class' => '', 'author' => '', 'company' => '', 'pagina' => '', 'image' => '', 'timthumb' => 'on'), $atts));
    $content = et_content_helper($content);
    $style = $style != '' ? ' style="' . $style . '"' : '';
    $id = $id != '' ? " id='" . esc_attr($id) . "'" : '';
    $class = $class != '' ? esc_attr(' ' . $class) : '';
    $orig_name = $author;
    $author = $author != '' ? "<span class='t-author'>{$author}</span>" : '';
    $company = $company != '' ? "<span class='t-position'>{$company}</span>" : '';
    $pagina = $pagina != '' ? "{$pagina}" : '';
    $image_markup = '';
    if ($image != '') {
        $image = $timthumb == 'on' ? et_new_thumb_resize($image, 57, 57, '', $forstyle = true) : $image;
        $image_markup = "\r\n\t\t\t<div class='t-img'>\r\n\t\t\t\t<img src='{$image}' alt='{$orig_name}' />\r\n\t\t\t\t<span class='t-overlay'></span>\r\n\t\t\t</div>\r\n\t\t";
    }
    $output = "\r\n\t\t<div{$id} class='et-testimonial-box{$class}'{$style}>\r\n\t\t\t<div class='et-testimonial-content'>\r\n\t\t\t    <div class='et-testimonial clearfix'>\r\n\t\t\t\t\t<a href='{$pagina}'> {$image_markup} </a>\r\n\t\t\t\t\t{$content}\r\n\t\t\t\t\t<div class='t-info'>\r\n\t\t\t\t\t\t<a href='{$pagina}'> {$author} </a>\r\n\t\t\t\t\t\t{$company}\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t    </div>\r\n\t\t    <div class='t-bottom-arrow'></div>\r\n\t\t\t<div class='t-bottom-shadow'></div>\r\n\t\t</div>";
    return $output;
}
开发者ID:rogopag,项目名称:Chameleon,代码行数:19,代码来源:shortcodes.php



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


鲜花

握手

雷人

路过

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

请发表评论

全部评论

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

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

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

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

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