本文整理匯總了PHP中Goteo\Library\Text::GmapsLink方法的典型用法代碼示例。如果您正苦於以下問題:PHP Text::GmapsLink方法的具體用法?PHP Text::GmapsLink怎麽用?PHP Text::GmapsLink使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Goteo\Library\Text
的用法示例。
在下文中一共展示了Text::GmapsLink方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: if
<div class="image">
<?php if (!empty($user->avatar)): ?><img alt="<?php echo htmlspecialchars($user->name) ?>" src="<?php echo $user->avatar->getLink(80, 80, true); ?>" /><?php endif ?>
</div>
<?php if (isset($user->about)): ?>
<blockquote class="about">
<?php echo $user->about ?>
</blockquote>
<?php endif ?>
<dl>
<?php if (isset($user->location)): ?>
<dt class="location"><?php echo Text::get('profile-location-header'); ?></dt>
<dd class="location"><?php echo Text::GmapsLink($user->location); ?></dd>
<?php endif ?>
<?php if (!empty($user->webs)): ?>
<dt class="links"><?php echo Text::get('profile-webs-header'); ?></dt>
<dd class="links">
<ul>
<?php foreach ($user->webs as $link): ?>
<li><a href="<?php echo htmlspecialchars($link->url) ?>" target="_blank"><?php echo htmlspecialchars($link->url) ?></a></li>
<?php endforeach ?>
</ul>
</dd>
<?php endif ?>
<dt class="message"><?php echo Text::get('regular-send_message')?></dt>
<dd class="message"><a href="/user/profile/<?php echo htmlspecialchars($user->id) ?>/message"><?php echo Text::get('regular-send_message')?></a></dd>
</dl>
示例2: if
<h4><?php echo Text::get('profile-keywords-header'); ?></h4>
<p><?php echo $user->keywords; ?></p>
</div>
<?php endif ?>
<?php if (!empty($user->webs)): ?>
<div class="webs">
<h4><?php echo Text::get('profile-webs-header'); ?></h4>
<ul>
<?php foreach ($user->webs as $link): ?>
<li><a href="<?php echo htmlspecialchars($link->url) ?>" target="_blank"><?php echo htmlspecialchars($link->url) ?></a></li>
<?php endforeach ?>
</ul>
</div>
<?php endif ?>
<?php if (!empty($user->location)): ?>
<div class="location">
<h4><?php echo Text::get('profile-location-header'); ?></h4>
<p><?php echo Text::GmapsLink($user->location); ?></p>
</div>
<?php endif ?>
<?php if (!empty($this['projects'])): ?>
<div class="message">
<p><a href="/user/profile/<?php echo $user->id ?>/message"><?php echo Text::get('regular-send_message')?></a></p>
</div>
<?php endif ?>
</div>
示例3:
</blockquote>
<?php
}
?>
<dl>
<?php
if (isset($user->location)) {
?>
<dt class="location"><?php
echo Text::get('profile-location-header');
?>
</dt>
<dd class="location"><?php
echo Text::GmapsLink($user->location);
?>
</dd>
<?php
}
?>
<?php
if (!empty($user->webs)) {
?>
<dt class="links"><?php
echo Text::get('profile-webs-header');
?>
</dt>
<dd class="links">
<ul>