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


PHP Render::image方法代码示例

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


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

示例1: shared

 public static function shared($task)
 {
     $stats = array('lists' => array());
     // Get contacts
     $lists = BackupsModel::all(array('sync_task_id' => $task['id'], 'user_id' => $task['user_id'], 'entity_type' => static::$kind['list']))->toArray();
     if ($lists) {
         foreach ($lists as $list) {
             $data = json_decode($list['entity'], true);
             $stats['lists'][] = array('id' => $list['entity_id'], 'name' => $list['entity_title'], 'picture' => \Render::image('no-photo.png'), 'data' => $data);
         }
     }
     return $stats;
 }
开发者ID:unDemian,项目名称:gcdc-migrate,代码行数:13,代码来源:Tasks.php

示例2: profileImageUrl

 /**
  * Resize the google profile pic from it's URL
  *
  * @param null $user
  * @param int  $size
  *
  * @return string
  */
 public static function profileImageUrl($user = null, $size = 28)
 {
     if ($user) {
         if (isset($user['avatar'])) {
             $url = parse_url($user['avatar']);
             if (isset($url['query'])) {
                 $url['query'] = 'sz=' . $size;
                 return $url['scheme'] . '://' . $url['host'] . '/' . $url['path'] . '?' . $url['query'];
             } else {
                 if ($user['avatar']) {
                     return $user['avatar'] . '?sz=' . $size;
                 }
             }
         }
     }
     return Render::image('no-photo.jpg');
 }
开发者ID:unDemian,项目名称:gcdc-migrate,代码行数:25,代码来源:Util.php

示例3:

					</div>
				</div>
			</div>
		<?php 
}
?>

		<div class="col-sm-6 col-md-3">
			<div class="thumbnail new clearfix">
				<div class="big-avatar pull-left">
					<a href="<?php 
echo Render::link('accounts/add');
?>
">
						<img src="<?php 
echo Render::image('new-user.png');
?>
" alt="avatar" class="img-rounded img-responsive" title="Choose New Account">
					</a>
				</div>

				<div class="caption pull-left">
					<h3>Not done?</h3>

					<h6>Add as many accounts as you want</h6>
					<h6>Click the button below to add another one</h6>
					<br />

					<p>
						<a href="<?php 
echo Render::link('accounts/add');
开发者ID:unDemian,项目名称:gcdc-migrate,代码行数:31,代码来源:content.html.php

示例4: shared

 public static function shared($task)
 {
     $stats = array('calendars' => array());
     // Get calendars
     $calendars = CalendarsModel::withEvents($task['user_id'], $task['id']);
     if ($calendars) {
         foreach ($calendars as $calendar) {
             $stats['calendars'][] = array('id' => $calendar['calendar_id'], 'name' => $calendar['name'], 'picture' => \Render::image('no-photo.png'), 'data' => $calendar);
         }
     }
     return $stats;
 }
开发者ID:unDemian,项目名称:gcdc-migrate,代码行数:12,代码来源:Calendar.php

示例5:

		<div class="navbar-header">
			<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
				<span class="sr-only">Toggle navigation</span>
				<span class="icon-bar"></span>
				<span class="icon-bar"></span>
				<span class="icon-bar"></span>
			</button>
			<a class="navbar-brand <?php 
echo Router::$class == 'dashboard' ? 'active' : '';
?>
" href="<?php 
echo Render::link('dashboard');
?>
"><img src="<?php 
echo Render::image('icon.png');
?>
"/></a>
		</div>

		<div class="navbar-collapse collapse">
			<ul class="nav navbar-nav">
				<li <?php 
echo Router::$class == 'dashboard' ? 'class="active"' : '';
?>
><a href="<?php 
echo Render::link('dashboard');
?>
">Dashboard</a></li>
				<li <?php 
echo Router::$class == 'migrate' ? 'class="active"' : '';
开发者ID:unDemian,项目名称:gcdc-migrate,代码行数:30,代码来源:navigation-default.html.php

示例6: foreach

echo $stats['calendars'];
?>
</strong></i></div>
	<br />
	<hr class="clear"/>

	<div class="sub-block clearfix clear">
		<?php 
if (isset($migratedData['calendars'])) {
    ?>
			<?php 
    foreach ($migratedData['calendars'] as $calendar) {
        ?>
				<div class="col-xs-2 no-padding margin-bottom-md clearfix" style="overflow: none; word-wrap: none ">
					<img src="<?php 
        echo Render::image('no-photo.png');
        ?>
" width="24" class="img-responsive img-rounded pull-left" />
					&nbsp;<strong><?php 
        echo Util::wrap($calendar['name']);
        ?>
</strong>
				</div>
			<?php 
    }
    ?>
		<?php 
}
?>
	</div>
</section>
开发者ID:unDemian,项目名称:gcdc-migrate,代码行数:31,代码来源:calendar.html.php


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