source: branches/feature-module-paygent/data/smarty_extends/block.marquee.php @ 11658

Revision 11658, 569 bytes checked in by uehara, 14 years ago (diff)
  • Property svn:eol-style set to native
Line 
1<?php
2/**
3 * marquee¥¿¥°¤Ç°Ï¤à¡£
4 *
5 * DoCoMo¤Î·ÈÂÓüËö¤Î¾ì¹ç¤Ïmarquee¤ò»ÈÍѤ·¤Ê¤¤¡£
6 *
7 * @param string $value ÆþÎÏ
8 * @return string ½ÐÎÏ
9 */
10function smarty_block_marquee($params, $content, &$smarty, &$repeat) {
11    // {/marquee}¤Î¾ì¹ç¤Î¤ß½ÐÎϤ¹¤ë¡£
12    if ($repeat || !isset($content)) {
13        return null;
14    }
15
16    // ËöÈø¤Î²þ¹Ô¤Ê¤É¤ò¼è¤ê½ü¤¯¡£
17    $content = rtrim($content);
18
19    // marquee¥¿¥°¤ò»ÈÍѤ·¤Ê¤¤¾ì¹ç
20    if (defined('MOBILE_SITE') && GC_MobileUserAgent::getCarrier() == 'docomo') {
21        return "<div>\n$content\n</div>\n";
22    }
23
24    return "<marquee>\n$content\n</marquee>\n";
25}
26?>
Note: See TracBrowser for help on using the repository browser.