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


PHP app::format_date方法代码示例

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


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

示例1: build_twitter_feed

    function build_twitter_feed($var)
    {
        //print_r($xml->status);
        //$output = '<ul class="twitter-feed">';
        foreach ($var as $tweet) {
            //print_r($tweet);
            $text = url::make_urls_links($tweet->text);
            $date = app::format_date($tweet->created_at, $app["bahasa"], "A");
            $output .= '<div class="tweet">
						<div class="title"><a class="title" target="blank" href="http://twitter.com/' . $tweet->user->screen_name . '">@' . $tweet->user->screen_name . '</a></div>
						<p>' . $text . '</p>
						<div class="hour">' . $date . '</div>
						<div class="clear"></div>
						</div>';
            //$output .= '<li>'.$text.'</li>';
        }
        //$output .= '</ul>';
        return $output;
    }
开发者ID:salomay,项目名称:refreshin,代码行数:19,代码来源:url.php

示例2:

         <?php 
 $stat = "index.php?act=set_status&p_id={$rshasil['id']}&status=" . $rshasil["status"];
 if ($rshasil["status"] == 'aktif') {
     echo '<a href="' . $stat . '"  title="' . $rshasil[status] . '">
               <span class="ion-happy-outline"></span>
               </a>';
 } else {
     echo '<a href="' . $stat . '" title="' . $rshasil[status] . '">
               <span class="ion-sad-outline"></span>
               </a>';
 }
 ?>
       </td>
       <td style="text-align:center;"><?php 
 if ($rshasil["tgl_post"] != null && $rshasil["tgl_post"] != '0000-00-00') {
     $rshasil["tgl_post"] = $appx->format_date($rshasil["tgl_post"], '');
 } else {
     $rshasil["tgl_post"] = "";
 }
 echo $rshasil["tgl_post"];
 ?>
       </td>
       <td style="text-align:center;"><?php 
 if ($rshasil["tgl_modif"] != null && $rshasil["tgl_modif"] != '0000-00-00') {
     $rshasil["tgl_modif"] = $appx->format_date($rshasil["tgl_modif"], '');
 } else {
     $rshasil["tgl_modif"] = "";
 }
 echo $rshasil["tgl_modif"];
 ?>
       </td>
开发者ID:salomay,项目名称:refreshin,代码行数:31,代码来源:tmp_browse.php

示例3:

				<div class="latest_update add_fix">
				
				<?php 
$tglnya = "";
$h1 = true;
while ($dnews = $dbu->fetch($rnews)) {
    $dnews[icon] = $appx->cekFile('/berita/icon/', $dnews[icon], 'default.png');
    $dnews[icon] = $app[data_www] . '/berita/icon/' . $dnews[icon];
    $dnews[thumb] = $appx->cekFile('/berita/thumb/', $dnews[thumb], 'default.jpg');
    $dnews[thumb] = $app[data_www] . '/berita/thumb/' . $dnews[thumb];
    if ($h1 == true) {
        $tglnya = $dnews[tgl_post];
        $h1 = false;
        ?>
						<h1><?php 
        echo $appx->format_date($dnews[tgl_post], 'id', 'N');
        ?>
<span class="border"></span></h1>
						<ul class="update_list update_list_news add_fix">
					<?php 
    }
    ?>
					<li>
							<a href="<?php 
    echo $app["www"] . "/" . $dbu->lookup('nama', 'action', "action='51'") . "/" . $urlx->shortLink($dnews[judul]) . "_" . $dnews[id] . "/";
    ?>
">
								<div class="img_box">
									<div class="icon"><img src="<?php 
    echo $dnews[icon];
    ?>
开发者ID:salomay,项目名称:refreshin,代码行数:31,代码来源:fill_news.php

示例4:

        ?>
"  /> <br> 
        <input type="checkbox" class="checkbox" name="p_favico_del" value="1">check to remove <br />
       <?php 
    }
}
?>
    <input name="p_favico" type="file" id="p_favico" />&nbsp;
  </div>
</div>
<br/>
<div>
  <div>tanggal update terakhir 
    <?php 
if ($form["tgl_modif"] != null && $form["tgl_modif"] != '0000-00-00') {
    $form["tgl_modif"] = $appx->format_date($form["tgl_modif"], 'id');
} else {
    $form["tgl_modif"] = "";
}
echo $form["tgl_modif"];
?>
</div>
<br/>
<hr/>
<br/>
  <div >Yang Bertanda * Harus disi</div><br/>
  <div class="footer">
    <input type="button" value="Update" onClick="set_action(this, 'update')"> 
    <input type="reset" value="Reset" name="reset" class="btn btn-warning">
      <input type="hidden" name="act">
      <input type="button" value="Cancel" id="cancel">
开发者ID:salomay,项目名称:refreshin,代码行数:31,代码来源:tmp_config.php

示例5: while

echo $dfa[lastUpdate];
?>
</p>
								<div class="user_tools">
									<a href="#"><i style="color:#085f7d;font-size:19px;" class="demo-icon icon-chat">&#xe802;</i> Multi Quote</a>
									<a href="#"><i style="color:#085f7d;font-size:19px;" class="demo-icon icon-comment">&#xe801;</i> Quote</a>
								</div>
							</div>
						</div> <!-- postlist -->						
						<?php 
//$lalala = "aaa[/qreq]";
//echo strpos($lalala,"[/qreq]");exit;
if ($nkomen > 0) {
    while ($dkomen = $dbu->fetch($rkomen)) {
        $tglpos = explode(" ", $dkomen[tgl_post]);
        $tglpost = $appx->format_date($tglpos[0], $_SESSION[bhs], 'N') . " | " . $tglpos[1];
        $tgljoin = $appx->format_date($dkomen[tgljoin], $_SESSION[bhs], 'N');
        $dkomen[avatar] = $appx->cekFile("/pengguna/avatar/", $dkomen[avatar]);
        $dkomen[avatar] = $app[data_www] . "/pengguna/avatar/" . $dkomen[avatar];
        $linkAva = $app["www"] . "/" . $dbu->lookup('nama', 'action', "action='8' and id_bahasa ='" . $_SESSION[bhs] . "'") . "/" . $urlx->shortLink($dkomen[username]) . "/";
        $hitJml = $dbu->count_record("SELECT count(id) as jumlah FROM " . $app[table][forum] . " WHERE id_user = '" . $dkomen[id] . "'");
        ?>
						<div class="postlist no-entry add_fix">
							<div class="entry-head">
								<div class="time_post"><?php 
        echo $tglpost;
        ?>
</div>
								<div class="shorcut_post">
									<div class="report"><a href="#"><i style="color:#fff;" class="demo-icon icon-attention">&#xe803;</i></a></div>
								</div>
开发者ID:salomay,项目名称:refreshin,代码行数:31,代码来源:fill_thread_article_detail.php

示例6: while

							<?php 
if ($nof <= 0) {
    ?>
								<h1 class="main_title" style="background:none;">TODAY<span class="border"></span></h1>
								<ul>
									<li>NO Article Found</li>
								</ul>
								</div>
							<?php 
} else {
    $tglnya = "";
    $h1 = true;
    while ($dforum = $dbu->fetch($rforum)) {
        if ($h1 == true) {
            $h1 = false;
            $tglnya = $appx->format_date($dforum[tgl_post], 'id', 'N');
            $now = $appx->format_date(date("Y-m-d"), 'id', 'N');
            $xtgl = $tglnya;
            if ($tglnya == $now) {
                $xtgl = "TODAY";
            }
            ?>
								<h1 class="main_title" style="background:none;"><?php 
            echo $xtgl;
            ?>
<span class="border"></span></h1>
								<ul>
							<?php 
            $avatar = $appx->cekFile('/pengguna/avatar/', $dforum[avatar], 'default.jpg');
            $avatar = $app[data_www] . '/pengguna/avatar/' . $avatar;
            $linkAva = $app["www"] . "/" . $dbu->lookup('nama', 'action', "action='8' and id_bahasa ='" . $_SESSION[bhs] . "'") . "/" . $urlx->shortLink($dforum[username]) . "/";
开发者ID:salomay,项目名称:refreshin,代码行数:31,代码来源:fill_thread_article.php

示例7: ucfirst

?>
/images/em.png"></a>
						</div>
						<div class="box_meta_overview">
							<h1><?php 
echo ucfirst($desbhs[nama]) . ", " . ucfirst($desbhs[kota]) . ", " . ucfirst($desbhs[provinsi]);
?>
</h1>
							<div class="box_postdate add_fix">
								<div class="det_post_by">by <label><a href="#"><?php 
echo ucfirst($desbhs[username]);
?>
</a></label></div>
								<span>|</span>
								<div class="det_date"><?php 
echo $appx->format_date($desbhs[diposting], $_SESSION[bhs]);
?>
</div>
							</div>
							<div class="litle_quotes"><img src="<?php 
echo $app["css_www"];
?>
/images/ic_q_left.png"><?php 
echo ucfirst($desbhs[slogan]);
?>
<img src="<?php 
echo $app["css_www"];
?>
/images/ic_q_right.png"></div>
						</div>
						<div class="box_main_info add_fix">
开发者ID:salomay,项目名称:refreshin,代码行数:31,代码来源:fill_detil_destinasi.php

示例8: header

 $xpid = "";
 if ($sub != "") {
     $xpid = str_replace("page-", "", $sub);
     $awal = ($xpid - 1) * $limitx;
     $limit = "LIMIT " . $awal . ", " . $limitx;
 } else {
     header("location:" . $app[www] . "/" . $dbu->lookup('nama', 'action', "action='41' and id_bahasa='" . $_SESSION[bhs] . "'") . "/" . $urlx->shortLink($p_id) . "/page-1/");
     //exit;
 }
 $pid = str_replace("-", "%", $p_id);
 $sql = "SELECT a.id, a.judul, a.id_destinasi, a.isi, a.tgl_post, a.tgl_modif as lastUpdate, b.username , b.avatar, b.tgl_post as tgljoin, c.nama as destinasi FROM " . $app[table][forum] . " as a LEFT JOIN " . $app[table][pengguna] . " as b ON(a.id_user = b.id) LEFT JOIN " . $app[table][destinasi] . " as d ON(a.id_destinasi = d.id) LEFT JOIN " . $app[table][destinasi_bahasa] . " as c ON(d.id_reff = c.id_reff) WHERE a.judul LIKE '" . $pid . "' AND c.id_bahasa ='" . $_SESSION[bhs] . "' AND a.tipe ='article' AND a.status ='aktif'";
 //echo $sql;exit;
 $dfa = $dbu->get_recordmix($sql);
 if ($dfa[id] != "") {
     $tglpos = explode(" ", $dfa[tgl_post]);
     $tglpost = $appx->format_date($tglpos[0], $_SESSION[bhs], 'N') . " | " . $tglpos[1];
     $tgljoin = $appx->format_date($dfa[tgljoin], $_SESSION[bhs], 'N');
     $dfa[avatar] = $appx->cekFile("/pengguna/avatar/", $dfa[avatar]);
     $dfa[avatar] = $app[data_www] . "/pengguna/avatar/" . $dfa[avatar];
     $linkAva = $app["www"] . "/" . $dbu->lookup('nama', 'action', "action='8' and id_bahasa ='" . $_SESSION[bhs] . "'") . "/" . $urlx->shortLink($dfa[username]) . "/";
     $hitJml = $dbu->count_record("SELECT count(id) as jumlah FROM " . $app[table][forum] . " WHERE id_user = '" . $_SESSION[member][id] . "'");
     if ($dfa[lastUpdate] != null && $dfa[lastUpdate] != '0000-00-00 00:00:00') {
         $tgledit = explode(" ", $dfa[lastUpdate]);
         $tglEdit = $appx->format_date($tgledit[0], $_SESSION[bhs], 'N') . " " . $tgledit[1];
         $dfa[lastUpdate] = $tglEdit;
     } else {
         $dfa[lastUpdate] = $tglpost;
     }
     #per page komen -----------------------
     $sql = "SELECT a.id,a.id_komen, a.isi , a.tgl_post, a.tgl_modif as lastUpdate, b.username , b.avatar, b.tgl_post as tgljoin FROM " . $app[table][forum_komen] . " as a LEFT JOIN " . $app[table][pengguna] . " as b ON(a.id_user = b.id) WHERE a.id_forum = '" . $dfa[id] . "' AND a.status ='aktif' ORDER BY tgl_post DESC " . $limit;
     //echo $sql; exit;
开发者ID:salomay,项目名称:refreshin,代码行数:31,代码来源:coretan_thread_detail.php

示例9:

									<span class="border"></span>
									<h2><?php 
    echo $newsbhs[judul];
    ?>
</h2>
									<p><?php 
    echo $newsbhs[sinopsis];
    ?>
</p>
									<div class="post_by">oleh <i><?php 
    echo $dbu->lookup('nama', 'pengguna', "id='" . $rsnew[id_user] . "'");
    ?>
</i></div>
									<div class="info">
										<div class="date"><?php 
    echo $appx->format_date($rsnew[tgl_post], 'id', 'N');
    ?>
</div>
										<div class="view"><?php 
    echo $appx->number_to_K($rsnew[hit]);
    ?>
</div>
									</div>
								</div>
							</a>
						</li>
							<?php 
    $hit++;
}
?>
						
开发者ID:salomay,项目名称:refreshin,代码行数:30,代码来源:fill_home.php


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