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


PHP has_slot函数代码示例

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


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

示例1: use_plop_theme

/**
 * Set the theme
 * @param Mixed $css String or array
 */
function use_plop_theme($class = '', $theme = null)
{
    if (!$theme) {
        $theme = sfPlop::get('sf_plop_theme');
    }
    if (preg_match('/\\s/', $theme) !== false) {
        $subthemes = explode(' ', $theme);
        $theme = array_shift($subthemes);
        $class .= ' ' . implode(' ', $subthemes);
    }
    $themes = sfPlop::get('sf_plop_loaded_themes');
    if ($theme != false && is_string($theme) && isset($themes[$theme])) {
        if (isset($themes[$theme]['css'])) {
            use_plop_stylesheet($themes[$theme]['css']);
        }
        if (isset($themes[$theme]['js'])) {
            use_plop_javascript($themes[$theme]['js']);
        }
    } else {
        $theme = '';
    }
    if (has_slot('sf_plop_theme') && $theme == sfPlop::get('sf_plop_theme')) {
        slot('sf_plop_theme', get_slot('sf_plop_theme') . $theme . ' ' . $class);
    } else {
        slot('sf_plop_theme', $theme . ' ' . $class);
    }
}
开发者ID:noreiller,项目名称:sfPlopPlugin,代码行数:31,代码来源:sfPlopHelper.php

示例2: seo_admin_bar

/**
 * seo_admin_bar
 *
 * @return includes an SEO menu bar in your project to edit meta and sitemap data
 * @author Brent Shaffer
 */
function seo_admin_bar()
{
    if (has_slot('seo_admin_bar')) {
        include_slot('seo_admin_bar');
    } else {
        include_component('csSEO', 'seo_admin_bar');
    }
}
开发者ID:bshaffer,项目名称:Symplist,代码行数:14,代码来源:SeoHelper.php

示例3: include_slot

<?php 
    include_slot('op_mobile_footer_menu');
}
?>

<?php 
echo op_within_page_link('');
?>
<a name="bottom"></a>

<?php 
include_component('default', 'nav', array('type' => 'mobile_global', 'line' => false));
?>

<?php 
if (has_slot('op_mobile_footer')) {
    include_slot('op_mobile_footer');
} else {
    if ($sf_user->hasCredential('SNSMember')) {
        ?>
<table width="100%">
<tbody><tr><td align="center" bgcolor="<?php 
        echo $op_color["core_color_2"];
        ?>
">
<font color="<?php 
        echo $op_color["core_color_18"];
        ?>
"><a href="<?php 
        echo url_for('@homepage');
        ?>
开发者ID:te-koyama,项目名称:openpne,代码行数:31,代码来源:layout.php

示例4: include_component

  <div class="mainDiv">
  	<div class="globalheader">
    	<?php 
include_component('home', 'globalheader');
?>
    </div>
    <div class="header">
      <?php 
include_component('home', 'header');
?>
    </div>
    <div class="content">
      <div class="leftmenu">
        <div class="leftmenucontent">
          <?php 
if (has_slot('leftmenu')) {
    ?>
          	<?php 
    include_slot('leftmenu');
    ?>
          <?php 
}
?>
        </div>
      </div>
      <div class="contentMain"> <?php 
echo $sf_data->getRaw('sf_content');
?>
 </div>
    </div>
    <div class="footermark"> 
开发者ID:Ayaan123,项目名称:alumnisangam,代码行数:31,代码来源:layout.php

示例5: include_slot

<?php 
}
?>

<div id="body">
<?php 
if (has_slot('submenu')) {
    ?>
<ul id="submenu">
<?php 
    include_slot('submenu');
    ?>
</ul>
<?php 
}
if (has_slot('title')) {
    ?>
<h2><?php 
    include_slot('title');
    ?>
</h2>
<?php 
}
?>

<?php 
if ($sf_user->hasFlash('error')) {
    ?>
<p id="flashError" class="flash"><?php 
    echo __($sf_user->getFlash('error'));
    ?>
开发者ID:shotaatago,项目名称:OpenPNE3,代码行数:31,代码来源:layout.php

示例6: date

  		</ul>
  		<ul id="partners">
        <li class="partner_wearenashville"><a href="http://www.wearenashville.org" title="We Are Nashville">We Are Nashville</a></li>
        <li class="partner_nashvillest"><a href="http://www.nashvillest.com" title="Nashvillest">Nashvillest</a></li>
        <li class="partner_unitedway"><a href="http://www.unitedwaynashville.org" title="United Way">United Way Nashville</a></li>
        <li class="partner_coolpeoplecare"><a href="http://coolpeoplecare.org" title="Cool People Care">Cool People Care</a></li>
      </ul>
  		<div class="center">&copy;<?php 
echo date('Y');
?>
 Donate Nashville</div>
		</div>
	</div>
	
	<?php 
if (has_slot('popUp')) {
    ?>
	 <div id="popup">
	   <?php 
    include_slot('popUp');
    ?>
	 </div>
	<?php 
}
?>
	
	
	<script type="text/javascript">
  var uservoiceOptions = {
    /* required */
    key: 'donatenashville',
开发者ID:bshaffer,项目名称:Donate-Nashville,代码行数:31,代码来源:layout.php

示例7: include_http_metas

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<?php 
include_http_metas();
include_metas();
include_title();
include_stylesheets();
include_javascripts();
?>
	<link rel="Shortcut Icon" type="image/x-icon" href="favicon.ico" />
<?php 
if (has_slot('inline_styles')) {
    ?>
	<style type="text/css">
<?php 
    include_slot('inline_styles');
    ?>
	</style>
<?php 
}
?>
</head>
<body class="<?php 
echo $_request->getParameter('module') . '-' . $_request->getParameter('action');
?>
">

<?php 
if (0 && CORE_ENVIRONMENT !== 'prod') {
    ?>
开发者ID:kc5nra,项目名称:RevTK,代码行数:31,代码来源:layoutView.php

示例8: include_component

            <td class="remaining"><div id="counter"></div></td>
	            <td class="datetime"><div id="clocker"></div></td>
            <td class="languages">
              <div class="languages_floater">
                <ul>
                  <?php 
include_component('headerMenu', 'langSelect');
?>
                </ul>
              </div>
            </td>
          </tr>
        </table>
      </div>
      <div class="center" style="<?php 
if (has_slot('bannerHeader')) {
    ?>
background:url(<?php 
    include_slot('bannerHeader');
    ?>
) no-repeat center top;<?php 
}
?>
">
        <div class="banner">
          <?php 
include_slot('bannerLogo');
?>
        </div>
        <div class="controllers">
          <div class="searchbox">
开发者ID:vcgato29,项目名称:poff,代码行数:31,代码来源:layout_old.php

示例9: slot

$t->diag('get_partial()');
sfConfig::set('mod_module_partial_view_class', 'MyTest');

$t->is(get_partial('module/dummy'), '==RENDERED==', 'get_partial() uses the class specified in partial_view_class for the given module');
$t->is(get_partial('MODULE/dummy'), '==RENDERED==', 'get_partial() accepts a case-insensitive module name');

// slots tests
sfContext::getInstance()->inject('response', 'sfWebResponse');

$t->diag('get_slot()');
$t->is(get_slot('foo', 'baz'), 'baz', 'get_slot() retrieves default slot content');
slot('foo', 'bar');
$t->is(get_slot('foo', 'baz'), 'bar', 'get_slot() retrieves slot content');

$t->diag('has_slot()');
$t->ok(has_slot('foo'), 'has_slot() checks if a slot exists');
$t->ok(!has_slot('doo'), 'has_slot() checks if a slot does not exist');

$t->diag('include_slot()');
ob_start();
include_slot('foo');
$t->is(ob_get_clean(), 'bar', 'include_slot() prints out the content of an existing slot');

ob_start();
include_slot('doo');
$t->is(ob_get_clean(), '', 'include_slot() does not print out the content of an unexisting slot');

ob_start();
include_slot('doo', 'zoo');
$t->is(ob_get_clean(), 'zoo', 'include_slot() prints out the default content specified for an unexisting slot');
开发者ID:nationalfield,项目名称:symfony,代码行数:30,代码来源:PartialHelperTest.php

示例10: include_slot

    ?>
 				<?php 
    include_slot('a-breadcrumb');
    ?>
 		<?php 
} elseif ($page) {
    ?>
 				<?php 
    include_component('aNavigation', 'breadcrumb', array('root' => '/', 'active' => $page['slug'], 'name' => 'component', 'separator' => ' /'));
    ?>
 		<?php 
}
?>

     <?php 
if (has_slot('a-subnav')) {
    ?>
       <?php 
    include_slot('a-subnav');
    ?>
     <?php 
} elseif ($page) {
    ?>
 		  <?php 
    include_component('a', 'subnav', array('page' => $page));
    ?>
 		<?php 
}
?>

		<div id="a-content">
开发者ID:quafzi,项目名称:timpany-prototype,代码行数:31,代码来源:layout.php

示例11: include_slot

        include_slot('og_title');
        ?>
" />
    <?php 
    } else {
        ?>
      <meta property="og:title" content="<?php 
        echo __('WEBSITE_HOMEPAGE_META_OG_TITLE');
        ?>
" />
    <?php 
    }
    ?>

    <?php 
    if (has_slot('og_description')) {
        ?>
      <meta property="og:description" content="<?php 
        include_slot('og_description');
        ?>
" />
    <?php 
    } else {
        ?>
      <meta property="og:description" content="<?php 
        echo __('WEBSITE_HOMEPAGE_SECONDARY_COPY');
        ?>
" />
    <?php 
    }
    ?>
开发者ID:ntemple,项目名称:intelli-plancake,代码行数:31,代码来源:login_layout.php

示例12: include_component_slot

<?php 
echo $sf_content;
?>
</div>
<!-- Right Column -->
<div id="rightcolumn">

<div class="notes">
<?php 
include_component_slot('sidebar');
?>
</div>


<?php 
if (has_slot('filters')) {
    ?>
  <?php 
    include_slot('filters');
} else {
    ?>
	<!-- Notes / Articles Box 
	<div class="notes"><h2>This is a Notice!</h2>
	
	<p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Duis dignissim vulputate leo. </p>
	<ul>
	<li>Donec mauris. Suspendisse potenti. </li>
	<li>Class aptent taciti sociosqu ad litora </li>
	<li>torquent per conubia nostra, per inceptos himenaeos. </li>
	<li>Aliquam molestie, erat non ultricies elementum, </li>
	<li>ante nulla hendrerit erat, sed laoreet </li>
开发者ID:anvaya,项目名称:nckids,代码行数:31,代码来源:layout.php

示例13: __

    echo __($sf_user->getFlash('notice'));
    ?>
      </div>
    <?php 
}
?>

    <div id="page-content">
      <?php 
echo $sf_content;
?>
    </div>
  </div>
  <div id="footer-spacer"></div>
</div>

<footer class="specific-footer">
  <?php 
echo Doctrine::getTable("Scripts")->getSingleton()->backend_bottom;
?>
</footer>
<?php 
if (!has_slot('disable_support')) {
    ?>

<?php 
}
?>
</body>
</html>
开发者ID:sensorsix,项目名称:app,代码行数:30,代码来源:layout.php

示例14: include_slot

?>

                    <?php 
if (has_slot('leftcol')) {
    ?>
                        <div class="three  columns">
                            <?php 
    include_slot('leftcol');
    ?>
                        </div>
                    <?php 
}
?>

                    <?php 
if (has_slot('leftcol')) {
    ?>
                        <div class="eight columns">
                        <?php 
} else {
    ?>
                            <div class="eight columns centered">
                            <?php 
}
?>
                                
                            <?php 
echo $sf_content;
?>
                        </div>
                    </div>
开发者ID:rbolliger,项目名称:otokou,代码行数:31,代码来源:layout.php

示例15: include_slot

            
                <div id="side_column">
                    <?php 
if (has_slot('sidebar')) {
    ?>
                        <?php 
    include_slot('sidebar');
    ?>
                    <?php 
}
?>
                </div><!-- end of side column -->

                <div id="main_column">
                    <?php 
if (has_slot('main')) {
    ?>
                        <?php 
    include_slot('main');
    ?>
                    <?php 
}
?>
                </div> <!-- end of main column -->

                <div class="cleaner"></div>
            </div> <!-- end of content -->
            <div id="templatemo_footer_bar">
                Copyright © 2010 <a href="http://kszk.sch.bme.hu/webteam">KSZK Webteam</a> |
                Designed by <a href="http://www.templatemo.com" target="_parent">Free CSS Templates</a> |
                Validate <a href="http://validator.w3.org/check?uri=referer">XHTML</a> &amp; <a href="http://jigsaw.w3.org/css-validator/check/referer">CSS</a>
开发者ID:szelpe,项目名称:cukorka,代码行数:30,代码来源:layout.php


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