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

PHP getDefaultSizedImage函数代码示例

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

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



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

示例1: theme_content

    function theme_content($map)
    {
        global $_zp_current_image, $points;
        ?>
		<!-- Colorbox section -->
		<div id="images">
			<?php 
        $points = array();
        while (next_image()) {
            if ($map) {
                $coord = getGeoCoord($_zp_current_image);
                if ($coord) {
                    $points[] = $coord;
                }
            }
            ?>
				<div class="image">
					<div class="imagethumb">
						<?php 
            if (isImagePhoto()) {
                // colorbox is only for real images
                $link = html_encode(getDefaultSizedImage()) . '" class="thickbox"';
            } else {
                $link = html_encode(getImageURL()) . '"';
            }
            ?>
						<a href="<?php 
            echo $link;
            ?>
" title="<?php 
            echo getBareImageTitle();
            ?>
">
							<?php 
            printImageThumb(getImageTitle());
            ?>
						</a></div>
				</div>
				<?php 
        }
        ?>
		</div>
		<br class="clearall" />
		<?php 
        @call_user_func('printSlideShowLink');
    }
开发者ID:rb26,项目名称:zenphoto,代码行数:46,代码来源:functions.php


示例2: loadAlbum

function loadAlbum($album)
{
    global $gallery, $_zp_current_album, $_zp_current_image;
    $subalbums = $album->getSubAlbums();
    $count = 0;
    foreach ($subalbums as $folder) {
        $subalbum = new Album($gallery, $folder);
        $count = $count + loadAlbum($subalbum);
    }
    $_zp_current_album = $album;
    if (getNumImages() > 0) {
        echo "<br />" . $album->name . "{";
        while (next_image(true)) {
            if (isImagePhoto($_zp_current_image)) {
                echo '<img src="' . getImageThumb() . '" height="8" width="8" /> | <img src="' . getDefaultSizedImage() . '" height="20" width="20" />' . "\n";
            } else {
                echo '<img src="' . getImageThumb() . '" height="8" width="8" /> | ';
            }
            $count++;
        }
        echo "}<br/>\n";
    }
    return $count;
}
开发者ID:ItsHaden,项目名称:epicLanBootstrap,代码行数:24,代码来源:admin-cache-images.php


示例3: printCustomSizedImage

">
					<?php 
            printCustomSizedImage(getBareImageTitle(), null, 160, 120, 160, 120, null, null, 'thumb', null, true);
            ?>
				</a>
			<?php 
        } else {
            ?>
			<li class="thumb-portrait">
				<div class="album-tools-portrait">
						<?php 
            if ($zpfocus_use_colorbox && !isImageVideo()) {
                ?>
<a class="album-tool" rel="zoom" href="<?php 
                if ($zpfocus_cbtarget) {
                    echo htmlspecialchars(getDefaultSizedImage());
                } else {
                    echo htmlspecialchars(getUnprotectedImageURL());
                }
                ?>
" title="<?php 
                echo getBareImageTitle();
                ?>
"><img src="<?php 
                echo $_zp_themeroot;
                ?>
/images/search.png" alt="Zoom Image" /></a><?php 
            }
            ?>
						<?php 
            if (function_exists('printCommentForm') && $_zp_current_image->getCommentsAllowed() && $_zp_current_image->getCommentCount() > 0) {
开发者ID:kokyandrei,项目名称:Unsupported,代码行数:31,代码来源:album.php


示例4: theme_content

    function theme_content($map)
    {
        global $_zp_current_image, $points;
        ?>
		<!-- Colorbox section -->
		<div id="content">
			<div id="main">
				<div id="images">
					<?php 
        $points = array();
        $firstImage = null;
        $lastImage = null;
        while (next_image()) {
            // Colorbox does not do video
            if (is_null($firstImage)) {
                $lastImage = imageNumber();
                $firstImage = $lastImage;
            } else {
                $lastImage++;
            }
            ?>
						<div class="image">
							<div class="imagethumb">
								<?php 
            if ($map) {
                $coord = getGeoCoord($_zp_current_image);
                if ($coord) {
                    $points[] = $coord;
                }
            }
            $annotate = annotateImage();
            if (isImagePhoto()) {
                // colorbox is only for real images
                echo '<a href="' . html_encode(getDefaultSizedImage()) . '" class="thickbox"';
            } else {
                echo '<a href="' . html_encode(getImageURL()) . '"';
            }
            echo " title=\"" . $annotate . "\">\n";
            printImageThumb($annotate);
            echo "</a>";
            ?>
							</div>
						</div>
						<?php 
        }
        echo '<div class="clearage"></div>';
        if (!empty($points) && $map) {
            function map_callback($map)
            {
                global $points;
                foreach ($points as $coord) {
                    addGeoCoord($map, $coord);
                }
            }
            ?>
						<div id="map_link">
						<?php 
            printGoogleMap(NULL, NULL, NULL, 'album_page', 'map_callback');
            ?>
						</div>
						<?php 
        }
        @call_user_func('printSlideShowLink', NULL, 'text-align:center;');
        ?>
				</div><!-- images -->
			<?php 
        @call_user_func('printRating');
        ?>
			</div><!-- main -->
			<div class="clearage"></div>
		<?php 
        if (isset($firstImage)) {
            printNofM('Photo', $firstImage, $lastImage, getNumImages());
        }
        ?>
		</div><!-- content -->
		<?php 
    }
开发者ID:rb26,项目名称:zenphoto,代码行数:78,代码来源:functions.php


示例5: printDefaultSizedImage

/**
 * Show video player with video loaded or display the image.
 *
 * @param string $alt Alt text
 * @param string $class Optional style class
 * @param string $id Optional style id
 */
function printDefaultSizedImage($alt, $class = NULL, $id = NULL)
{
    global $_zp_current_image;
    if (is_null($_zp_current_image)) {
        return;
    }
    if (!$_zp_current_image->getShow()) {
        $class .= " not_visible";
    }
    $album = $_zp_current_image->getAlbum();
    $pwd = $album->getPassword();
    if (!empty($pwd)) {
        $class .= " password_protected";
    }
    if (isImagePhoto()) {
        //Print images
        $html = '<img src="' . html_encode(pathurlencode(getDefaultSizedImage())) . '" alt="' . html_encode($alt) . '"' . ' width="' . getDefaultWidth() . '" height="' . getDefaultHeight() . '"' . ($class ? " class=\"{$class}\"" : "") . ($id ? " id=\"{$id}\"" : "") . " />";
        $html = zp_apply_filter('standard_image_html', $html);
        echo $html;
    } else {
        // better be a plugin class then
        echo $_zp_current_image->getContent();
    }
}
开发者ID:IliyanGochev,项目名称:zenphoto,代码行数:31,代码来源:template-functions.php


示例6: loadAlbum

function loadAlbum($album)
{
    global $gallery, $_zp_current_album, $_zp_current_image;
    $subalbums = $album->getAlbums();
    $started = false;
    $tcount = $count = 0;
    foreach ($subalbums as $folder) {
        $subalbum = new Album($gallery, $folder);
        if (!$subalbum->isDynamic()) {
            $tcount = $tcount + loadAlbum($subalbum);
        }
    }
    $theme = $gallery->getCurrentTheme();
    $id = 0;
    $parent = getUrAlbum($album);
    $albumtheme = $parent->getAlbumTheme();
    if (!empty($albumtheme)) {
        $theme = $albumtheme;
        $id = $parent->id;
    }
    loadLocalOptions($id, $theme);
    $_zp_current_album = $album;
    if ($album->getNumImages() > 0) {
        echo "<br />" . $album->name . ' ';
        while (next_image(true)) {
            $thumb = getImageThumb();
            if (strpos($thumb, 'i.php?') === false) {
                $thumb = NULL;
            }
            if (isImagePhoto($_zp_current_image)) {
                $image = getDefaultSizedImage();
                if (strpos($image, 'i.php?') === false) {
                    $image = NULL;
                }
            } else {
                $image = NULL;
                if ($_zp_current_image->objectsThumb == NULL) {
                    $thumb = NULL;
                }
            }
            if (!empty($thumb) || !empty($image)) {
                if (!$count) {
                    $started = true;
                    echo "{ ";
                } else {
                    echo ' | ';
                }
            }
            if (!empty($thumb)) {
                echo '<img src="' . $thumb . '" height="8" width="8" /> ';
            }
            if (!empty($image)) {
                echo ' <img src="' . $image . '" height="20" width="20" />';
            }
            if (!empty($thumb) || !empty($image)) {
                echo "\n";
            }
            $count++;
        }
        if ($started) {
            echo ' } ';
        }
        printf(ngettext('[%u image]', '[%u images]', $count), $count);
        echo "<br />\n";
    }
    return $count + $tcount;
}
开发者ID:hatone,项目名称:zenphoto-1.4.1.4,代码行数:67,代码来源:cache_images.php


示例7: html_encode

							<li>
								<?php 
                if (isImageVideo()) {
                    ?>
									<a class="thumb" href="<?php 
                    echo $_zp_themeroot;
                    ?>
/images/video-placeholder.jpg" title="<?php 
                    echo html_encode(getBareImageTitle());
                    ?>
">
										<?php 
                } else {
                    ?>
										<a class="thumb" href="<?php 
                    echo html_encode(getDefaultSizedImage());
                    ?>
" title="<?php 
                    echo html_encode(getBareImageTitle());
                    ?>
">
											<?php 
                }
                ?>
										<?php 
                printImageThumb(getAnnotatedImageTitle());
                ?>
</a>
									<?php 
                $fullimage = getFullImageURL();
                ?>
开发者ID:ariep,项目名称:ZenPhoto20-DEV,代码行数:31,代码来源:favorites.php


示例8: js_encode

            $desc = $desc1 . $desc2;
            echo 'description: \'' . js_encode($desc) . '\',' . "\n";
            echo 'link: \'' . html_encode(getAlbumURL()) . '\'' . "\n";
            echo '}' . "\n";
            $c++;
        }
    }
    while (next_image(true)) {
        if (isImagePhoto($_zp_current_image)) {
            if ($c == 0) {
                echo '{' . "\n";
            } else {
                echo ',{' . "\n";
            }
            echo 'thumb: \'' . getImageThumb() . '\',' . "\n";
            echo 'image: \'' . getDefaultSizedImage() . '\',' . "\n";
            echo 'big: \'' . getCustomImageURL(getOption('zpbase_galbigsize')) . '\',' . "\n";
            echo 'title: \'' . html_encode(getBareImageTitle()) . '\',' . "\n";
            $desc = getBareImageDesc();
            $desc = str_replace("\r\n", '<br />', $desc);
            $desc = str_replace("\r", '<br />', $desc);
            echo 'description: \'' . js_encode($desc) . '\',' . "\n";
            if (!getOption('zpbase_nodetailpage')) {
                echo 'link: \'' . html_encode(getImageURL()) . '\'' . "\n";
            }
            echo '}' . "\n";
            $c++;
        }
    }
    ?>
					];
开发者ID:BimbaLaszlo,项目名称:zpbase,代码行数:31,代码来源:album-galleria.php


示例9: printBaseSlideShow

function printBaseSlideShow()
{
    global $_zp_gallery, $_zp_gallery_page, $_myFavorites, $_zp_conf_vars, $_zp_themeroot, $isMobile, $isTablet;
    if (!isset($_POST['albumid'])) {
        return '<div class="errorbox" id="message"><h2>' . gettext('Invalid linking to the slideshow page.') . '</h2></div>';
    }
    //getting the image to start with
    if (!empty($_POST['imagenumber'])) {
        $imagenumber = sanitize_numeric($_POST['imagenumber']) - 1;
        // slideshows starts with 0, but zp with 1.
    } else {
        $imagenumber = 0;
    }
    // set pagenumber to 0 if not called via POST link
    if (isset($_POST['pagenr'])) {
        $pagenumber = sanitize_numeric($_POST['pagenr']);
    } else {
        $pagenumber = 1;
    }
    // getting the number of images
    if (!empty($_POST['numberofimages'])) {
        $numberofimages = sanitize_numeric($_POST['numberofimages']);
    } else {
        $numberofimages = 0;
    }
    //if ($imagenumber < 2 || $imagenumber > $numberofimages) {
    //	$imagenumber = 0;
    //}
    //getting the album to show
    if (!empty($_POST['albumid'])) {
        $albumid = sanitize_numeric($_POST['albumid']);
    } else {
        $albumid = 0;
    }
    if (isset($_POST['preserve_search_params'])) {
        // search page
        $search = new SearchEngine();
        $params = sanitize($_POST['preserve_search_params']);
        $search->setSearchParams($params);
        $searchwords = $search->getSearchWords();
        $searchdate = $search->getSearchDate();
        $searchfields = $search->getSearchFields(true);
        $page = $search->page;
        $returnpath = getSearchURL($searchwords, $searchdate, $searchfields, $page);
        $albumobj = new AlbumBase(NULL, false);
        $albumobj->setTitle(gettext('Search'));
        $albumobj->images = $search->getImages(0);
        $albumtitle = gettext('Search');
    } else {
        if (isset($_POST['favorites_page'])) {
            $albumobj = $_myFavorites;
            $returnpath = rewrite_path($_myFavorites->getLink() . '/' . $pagenumber, FULLWEBPATH . '/index.php?p=favorites' . '&page=' . $pagenumber);
            $albumtitle = gettext('Favorites');
        } else {
            $albumq = query_single_row("SELECT title, folder FROM " . prefix('albums') . " WHERE id = " . $albumid);
            $albumobj = newAlbum($albumq['folder']);
            $albumtitle = $albumobj->getTitle();
            if (empty($_POST['imagenumber'])) {
                $returnpath = $albumobj->getLink($pagenumber);
            } else {
                $image = newImage($albumobj, sanitize($_POST['imagefile']));
                $returnpath = $image->getLink();
            }
        }
    }
    if (!$albumobj->isMyItem(LIST_RIGHTS) && !checkAlbumPassword($albumobj)) {
        return '<div class="errorbox" id="message"><h2>' . gettext('This album is password protected!') . '</h2></div>';
    }
    $slideshow = '';
    $numberofimages = $albumobj->getNumImages();
    if ($numberofimages == 0) {
        return '<div class="errorbox" id="message"><h2>' . gettext('No images for the slideshow!') . '</h2></div>';
    }
    $images = $albumobj->getImages(0);
    // slideshow generate data for galleria
    ?>
		<script>
			var data = [
			<?php 
    for ($c = 0, $idx = 0; $c < $numberofimages; $c++, $idx++) {
        if (is_array($images[$idx])) {
            $filename = $images[$idx]['filename'];
            $album = newAlbum($images[$idx]['folder']);
            $image = newImage($album, $filename);
        } else {
            $filename = $images[$idx];
            $image = newImage($albumobj, $filename);
        }
        if (isImagePhoto($image)) {
            makeImageCurrent($image);
            echo '{' . "\n";
            echo 'thumb: \'' . getImageThumb() . '\',' . "\n";
            echo 'image: \'' . getDefaultSizedImage() . '\',' . "\n";
            echo 'big: \'' . getCustomImageURL(getOption('zpbase_galbigsize')) . '\',' . "\n";
            echo 'title: \'' . js_encode($image->getTitle()) . '\',' . "\n";
            $desc = $image->getDesc();
            $desc = str_replace("\r\n", '<br />', $desc);
            $desc = str_replace("\r", '<br />', $desc);
            echo 'description: \'' . js_encode($desc) . '\',' . "\n";
            if (!getOption('zpbase_nodetailpage')) {
//.........这里部分代码省略.........
开发者ID:BimbaLaszlo,项目名称:zpbase,代码行数:101,代码来源:functions.php


示例10: header

} else {
    header('Content-Type: application/xml');
    $path = '';
    $levels = explode('/', getAlbumLinkURL());
    foreach ($levels as $v) {
        $path = $path . '../';
    }
    $path = substr($path, 0, -1);
    echo '<?xml version="1.0" encoding="UTF-8"?>
	<simpleviewerGallery title=""  maxImageWidth="' . $maxImageWidth . '" maxImageHeight="' . $maxImageHeight . '" textColor="' . $textColor . '" frameColor="' . $frameColor . '" frameWidth="' . $frameWidth . '" stagePadding="' . $stagePadding . '" thumbnailColumns="' . $thumbnailColumns . '" thumbnailRows="' . $thumbnailRows . '" navPosition="' . $navPosition . '" enableRightClickOpen="' . $enableRightClickOpen . '" backgroundImagePath="' . $backgroundImagePath . '" imagePath="' . $path . '" thumbPath="' . $path . '">';
    while (next_image(true, 0, NULL, NULL, true)) {
        if (isImagePhoto()) {
            // simpleviewer does not do videos
            ?>
			<image><filename><?php 
            echo getDefaultSizedImage();
            ?>
</filename>
				<caption>
				<![CDATA[<a href="<?php 
            echo htmlspecialchars(getImageLinkURL());
            ?>
" title="<?php 
            echo gettext('Open In New Window');
            ?>
">
					<font face="Times"><u><b><em><?php 
            echo getImageTitle();
            ?>
</font></em></b></u></a></u>
					<br /></font><?php 
开发者ID:ItsHaden,项目名称:epicLanBootstrap,代码行数:31,代码来源:album.php


示例11: gettext

    ?>
" data-role="button"><?php 
    echo gettext("next");
    ?>
</a>
						<?php 
}
?>
					</div>
					<div id="image">

						<?php 
if (isImagePhoto()) {
    ?>
							<img src="<?php 
    echo html_encode(pathurlencode(getDefaultSizedImage()));
    ?>
" alt="<?php 
    printBareImageTitle();
    ?>
" style="max-width:<?php 
    echo getDefaultWidth();
    ?>
px"/>
							<?php 
} else {
    printDefaultSizedImage(getImageTitle());
}
if (isImageVideo() && getOption('zpmobile_mediadirectlink')) {
    ?>
							<p><a href="<?php 
开发者ID:rauldobrota,项目名称:zenphoto,代码行数:31,代码来源:image.php


示例12: printDefaultSizedImageAlt

function printDefaultSizedImageAlt($alt, $class = NULL, $id = NULL)
{
    echo "<img style=\"filter: alpha(opacity=0); -moz-opacity: 0; -khtml-opacity: 0; opacity: 0;\" onload=\"opacity('fadein', 0, 100, 500)\" id=\"fadein\" src=\"" . getDefaultSizedImage() . "\" alt=\"{$alt}\"" . " width=\"" . getDefaultWidth() . "\" height=\"" . getDefaultHeight() . "\"" . ($class ? " class=\"{$class}\"" : "") . ($id ? " id=\"{$id}\"" : "") . " />";
}
开发者ID:Imagenomad,项目名称:Unsupported,代码行数:4,代码来源:functions.php


示例13: printDefaultSizedImage

/**
 * Show video player with video loaded or display the image.
 *
 * @param string $alt Alt text
 * @param string $class Optional style class
 * @param string $id Optional style id
 */
function printDefaultSizedImage($alt, $class = NULL, $id = NULL)
{
    global $_zp_current_image;
    if (is_null($_zp_current_image)) {
        return;
    }
    if (!$_zp_current_image->getShow()) {
        $class .= " not_visible";
    }
    $album = $_zp_current_image->getAlbum();
    $pwd = $album->getPassword();
    if (zp_loggedin() && !empty($pwd)) {
        $class .= " password_protected";
    }
    if (isImagePhoto()) {
        //Print images
        echo '<img src="' . htmlspecialchars(getDefaultSizedImage()) . '" alt="' . html_encode($alt) . '"' . ' title="' . html_encode($alt) . '"' . ' width="' . getDefaultWidth() . '" height="' . getDefaultHeight() . '"' . ($class ? " class=\"{$class}\"" : "") . ($id ? " id=\"{$id}\"" : "") . " />";
    } else {
        // better be a plugin class then
        echo $_zp_current_image->getBody();
    }
}
开发者ID:ItsHaden,项目名称:epicLanBootstrap,代码行数:29,代码来源:template-functions.php



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


鲜花

握手

雷人

路过

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

请发表评论

全部评论

专题导读
上一篇:
PHP getDefaultXssTags函数代码示例发布时间:2022-05-15
下一篇:
PHP getDefaultLanguage函数代码示例发布时间: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