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


PHP Loader::Helper方法代码示例

本文整理汇总了PHP中Loader::Helper方法的典型用法代码示例。如果您正苦于以下问题:PHP Loader::Helper方法的具体用法?PHP Loader::Helper怎么用?PHP Loader::Helper使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Loader的用法示例。


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

示例1: defined

<?php

defined('C5_EXECUTE') or die("Access Denied.");
$textHelper = Loader::helper("text");
$imgHelper = Loader::Helper('image');
// now that we're in the specialized content file for this block type,
// we'll include this block type's class, and pass the block to it, and get
// the content
if (count($cArray) > 0) {
    ?>
	
	<?php 
    for ($i = 0; $i < count($cArray); $i++) {
        $cobj = $cArray[$i];
        $target = $cobj->getAttribute('nav_target');
        $title = $cobj->getCollectionName();
        $date = $cobj->getCollectionDatePublic('Y/m/d');
        ?>

	<div class="grid_4 main-content-thumb">
	<h4><?php 
        echo "&#151; " . $date;
        ?>
</h4>
	<div class="image-link">
	<a <?php 
        if ($target != '') {
            ?>
 target="<?php 
            echo $target;
            ?>
开发者ID:nanpou,项目名称:concrete5,代码行数:31,代码来源:blog_index_thumbnail.php

示例2: defined

<?php

defined('C5_EXECUTE') or die("Access Denied.");
?>

<?php 
$_c = Page::getCurrentPage();
$valt = Loader::Helper('validation/token');
$token = '&' . $valt->getParameter();
if ($_c->getCollectionPath() != '/dashboard/news' && $_c->getCollectionPath() != '/dashboard/welcome' && !$_GET['_ccm_dashboard_external']) {
    ?>
<div class="well" style="margin-bottom: 0px">
	<?php 
    if ($_c->isCheckedOut()) {
        ?>
	<a href="#" id="ccm-nav-save-arrange" class="btn ccm-main-nav-arrange-option" style="display: none"><?php 
        echo t('Save Positioning');
        ?>
</a>
	<a href="<?php 
        echo DIR_REL;
        ?>
/<?php 
        echo DISPATCHER_FILENAME;
        ?>
?cID=<?php 
        echo $_c->getCollectionID();
        ?>
&approve=APPROVE&ctask=check-in&<?php 
        echo Loader::helper('validation/token')->getParameter();
        ?>
开发者ID:ceko,项目名称:concrete5-1,代码行数:31,代码来源:header_newsflow.php

示例3: elseif

">
	<div>
	<?php 
echo $form->checkbox($controller->field('fileIDs') . "[]", $fileID, true);
?>
	<?php 
if ($templType == "js") {
    ?>
		<?php 
    echo $fileThumb;
    ?>

	<?php 
} elseif ($templType == "inline") {
    $image = File::getById($fileID);
    $ih = Loader::Helper('image');
    $ext = $image->getExtension();
    if (in_array($ext, ['jpeg', 'png', 'gif', 'jpg'])) {
        $thumb = $ih->getThumbnail($image, 32, 32, true);
        echo "<img src='{$thumb->src}'>";
    } elseif (file_exists(DIR_AL_ICONS . "/{$ext}.png")) {
        $path = \Core::getApplicationRelativePath() . "/concrete/images/icons/filetypes/{$ext}.png";
        echo "<img width='32' height='32' src='{$path}'>";
    }
    ?>
		
	<?php 
}
?>
	<span>
		<a class="title" href="<?php 
开发者ID:Bloodb0ne,项目名称:Concrete5_DevRepo,代码行数:31,代码来源:file_entry.php

示例4: defined

<?php

defined('C5_EXECUTE') or die("Access Denied.");
$form = Loader::Helper('form');
$selectedThemeID = 0;
$selectedTemplateID = 0;
if (is_object($selectedTheme)) {
    $selectedThemeID = $selectedTheme->getThemeID();
}
if (is_object($selectedTemplate)) {
    $selectedTemplateID = $selectedTemplate->getPageTemplateID();
}
if (is_object($selectedType)) {
    $selectedTypeID = $selectedType->getPageTypeID();
}
?>

<div class="ccm-ui">
<form method="post" data-dialog-form="design" action="<?php 
echo $controller->action('submit');
?>
">

    <input type="hidden" name="sitemap" value="1" />
    
    <?php 
if ($cp->canEditPageTemplate()) {
    ?>
        <?php 
    echo $form->label('pTemplateID', t('Page Template'));
    ?>
开发者ID:seebaermichi,项目名称:concrete5,代码行数:31,代码来源:design.php

示例5: defined

<?php

defined('C5_EXECUTE') or die("Access Denied.");
$textHelper = Loader::helper("text");
$imgHelper = Loader::Helper('image');
$dateHelper = Loader::Helper('date');
/* @var $dateHelper DateHeler */
// now that we're in the specialized content file for this block type,
// we'll include this block type's class, and pass the block to it, and get
// the content
if (count($cArray) > 0) {
    ?>
	
	<?php 
    for ($i = 0; $i < count($cArray); $i++) {
        $cobj = $cArray[$i];
        $target = $cobj->getAttribute('nav_target');
        $title = $cobj->getCollectionName();
        $date = $dateHelper->formatDate($cobj->getCollectionDatePublic(), true);
        ?>

	<div class="grid_4 main-content-thumb">
	<h4><?php 
        echo "&#151; " . $date;
        ?>
</h4>
	<div class="image-link">
	<a <?php 
        if ($target != '') {
            ?>
 target="<?php 
开发者ID:ojalehto,项目名称:concrete5-legacy,代码行数:31,代码来源:blog_index_thumbnail.php

示例6: validate

 protected function validate()
 {
     $vt = Loader::helper('validation/strings');
     $vn = Loader::Helper('validation/numbers');
     $dt = Loader::helper("form/date_time");
     if (!$vn->integer($this->post('cParentID'))) {
         $this->error->add(t('You must choose a parent page for this News entry.'));
     }
     if (!$vn->integer($this->post('ctID'))) {
         $this->error->add(t('You must choose a page type for this News entry.'));
     }
     if (!$vt->notempty($this->post('newsTitle'))) {
         $this->error->add(t('Title is required'));
     }
     if (!$this->error->has()) {
         Loader::model('collection_types');
         $ct = CollectionType::getByID($this->post('ctID'));
         $parent = Page::getByID($this->post('cParentID'));
         $parentPermissions = new Permissions($parent);
         if (!$parentPermissions->canAddSubCollection($ct)) {
             $this->error->add(t('You do not have permission to add a page of that type to that area of the site.'));
         }
     }
 }
开发者ID:hanicker,项目名称:Concrete5-EasyNews,代码行数:24,代码来源:controller.php

示例7: defined

<?php

defined('C5_EXECUTE') or die("Access Denied.");
$form = Loader::helper("form");
$nv = Loader::Helper('navigation');
?>
<div class="pageEntry" id="<?php 
echo $akID;
?>
_pageAttachmentRow<?php 
echo $pageID;
?>
">
	<div>
	<?php 
if ($mode == "multi") {
    ?>
		<?php 
    echo $form->checkbox($controller->field('pageIDs') . "[]", $pageID, true);
    ?>
	<?php 
} else {
    ?>
		<?php 
    echo $form->hidden($controller->field('pageIDs') . "[]", $pageID);
    ?>
	<?php 
}
?>

	<span>
开发者ID:Bloodb0ne,项目名称:Concrete5_DevRepo,代码行数:31,代码来源:page_entry.php


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