当前位置: 首页>>代码示例>>PHP>>正文


PHP hasPrevImage函数代码示例

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


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

示例1: getGalleryTitle

" title="Gallery Index"><?php 
echo getGalleryTitle();
?>
</a> | <?php 
printParentBreadcrumb();
printAlbumBreadcrumb();
?>
 | <?php 
printImageTitle();
?>
</span></h2>
	</div>

<div id="imgnav_tlg">
		<?php 
if (hasPrevImage()) {
    ?>
		<div style="float:left;">
		<a href="<?php 
    echo getPrevImageURL();
    ?>
">&laquo; previous photo</a>
		</div>
		<?php 
}
if (hasNextImage()) {
    ?>
		<div style="float:right;">
		<a href="<?php 
    echo getNextImageURL();
    ?>
开发者ID:Imagenomad,项目名称:Unsupported,代码行数:31,代码来源:image.php

示例2: zp_side_bar

function zp_side_bar()
{
    ?>
	<div id="sidebar">
		<?php 
    //-------------If you are in the Image Page
    if (in_context(ZP_IMAGE)) {
        ?>
				<div class="imgnav">
					<?php 
        if (hasPrevImage()) {
            ?>
					<div class="imgprevious"><a href="<?php 
            echo getPrevImageURL();
            ?>
" title="Previous Image"><img src="<?php 
            echo getPrevImageThumb();
            ?>
" /><br /><small>&laquo; prev  |</small></a></div>
					<?php 
        }
        if (hasNextImage()) {
            ?>
					<div class="imgnext"><a href="<?php 
            echo getNextImageURL();
            ?>
" title="Next Image"><img src="<?php 
            echo getNextImageThumb();
            ?>
" /><br /><small>| next &raquo;</small></a></div>
					<?php 
        }
        ?>
				</div> 
		<div id="sbinfo">
			<b>Album Name:</b> <?php 
        printAlbumTitle(true);
        ?>
<br />
			<b>Number of Photos:</b> <?php 
        echo getNumImages();
        ?>
<br />
			<b>Album Date:</b> <?php 
        printAlbumDate($before = "Date: ", $format = "%F");
        ?>
<br />
			<b>Album Description:</b> <?php 
        printAlbumDesc(true);
        ?>
<br />
			<b>Image Name:</b> <?php 
        echo getImageTitle();
        ?>
<br />
			<b>Image Description:</b> <?php 
        printImageDesc(true);
        ?>
<br />
		</div>
			<?php 
        //--------------- If you are in the Album Page
    } else {
        if (in_context(ZP_ALBUM)) {
            ?>
		<b>Album Name:</b> <?php 
            printAlbumTitle(true);
            ?>
<br />
		<b>Number of Pictures:</b> <?php 
            echo getNumImages();
            ?>
<br />
		<b>Album Date:</b> <?php 
            printAlbumDate($before = "Date: ", $format = "%F");
            ?>
<br /> 
		<b>Album Description:</b> <?php 
            printAlbumDesc(true);
            ?>
<br />		
<?php 
            //--------------- If you are in the Index Page
        } else {
            if (in_context(ZP_INDEX)) {
            }
        }
    }
    ?>

</div>
<?php 
}
开发者ID:Imagenomad,项目名称:Unsupported,代码行数:93,代码来源:functions.php

示例3: getPrevImageURL

?>
</h2>
	</div>

	<div class="imgnav">
		<?php 
if (hasPrevImage()) {
    ?>
		<a href="<?php 
    echo getPrevImageURL();
    ?>
" title="Previous Image">&laquo; prev</a>

		<?php 
}
if (hasPrevImage() && hasNextImage()) {
    ?>
		|

		<?php 
}
if (hasNextImage()) {
    ?>
		<a href="<?php 
    echo getNextImageURL();
    ?>
" title="Next Image">next &raquo;</a>
		<?php 
}
?>
	</div>
开发者ID:Imagenomad,项目名称:Unsupported,代码行数:31,代码来源:image.php

示例4: printPreloadScript

/**
 * @deprecated
 */
function printPreloadScript()
{
    deprecated_function_notify(gettext('printPreloadScript is deprecated. It is a helper for a specific theme and should be placed within that theme\'s "functions.php" script.'));
    global $_zp_current_image;
    $size = getOption('image_size');
    if (hasNextImage() || hasPrevImage()) {
        echo "<script type=\"text/javascript\">\n// <!-- <![CDATA[\n";
        if (hasNextImage()) {
            $nextimg = $_zp_current_image->getNextImage();
            echo "  nextimg = new Image();\n  nextimg.src = \"" . $nextimg->getSizedImage($size) . "\";\n";
        }
        if (hasPrevImage()) {
            $previmg = $_zp_current_image->getPrevImage();
            echo "  previmg = new Image();\n  previmg.src = \"" . $previmg->getSizedImage($size) . "\";\n";
        }
        echo "</script>\n\\ ]]> -->\n";
    }
}
开发者ID:hatone,项目名称:zenphoto-1.4.1.4,代码行数:21,代码来源:deprecated-functions.php

示例5: printPreloadScript

/**
 * Prints out the javascript to preload the next and previous images
 *
 */
function printPreloadScript()
{
    global $_zp_current_image;
    $size = getOption('image_size');
    if (hasNextImage() || hasPrevImage()) {
        echo "<script type=\"text/javascript\">\n";
        if (hasNextImage()) {
            $nextimg = $_zp_current_image->getNextImage();
            echo "  nextimg = new Image();\n  nextimg.src = \"" . $nextimg->getSizedImage($size) . "\";\n";
        }
        if (hasPrevImage()) {
            $previmg = $_zp_current_image->getPrevImage();
            echo "  previmg = new Image();\n  previmg.src = \"" . $previmg->getSizedImage($size) . "\";\n";
        }
        echo "</script>\n\n";
    }
}
开发者ID:ItsHaden,项目名称:epicLanBootstrap,代码行数:21,代码来源:template-functions.php


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