• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP showDate函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: showTable

function showTable($row, $count)
{
    $article = file_get_contents("tableArticles.html");
    $article = str_replace("{{TITLE}}", $row["title"], $article);
    $article = str_replace("{{DATE}}", showDate($row["publishdate"], 1), $article);
    $article = str_replace("{{COUNT}}", $row["id"], $article);
    return $article;
}
开发者ID:SRferrero,项目名称:DTTtask,代码行数:8,代码来源:DTTCore.php


示例2: getTag

 public function getTag()
 {
     $tags = Tag::all();
     return Datatables::of($tags)->edit_column('status', function ($row) {
         return showSelectStatus($row->id, $row->status, 'Kacana.product.tag.setStatusTag(' . $row->id . ', 1)', 'Kacana.product.tag.setStatusTag(' . $row->id . ', 0)');
     })->edit_column('created', function ($row) {
         return showDate($row->created);
     })->edit_column('updated', function ($row) {
         return showDate($row->updated);
     })->add_column('action', function ($row) {
         return showActionButton('Kacana.product.tag.showEditTagForm(' . $row->id . ')', 'Kacana.product.tag.removeTag(' . $row->id . ')', true);
     })->make(true);
 }
开发者ID:kacana,项目名称:admin,代码行数:13,代码来源:TagController.php


示例3: GetHighScoreList

 public function GetHighScoreList()
 {
     $output = "<ul>\n";
     $query = "SELECT * FROM dicegame ORDER BY score DESC limit 5";
     $result = mysqli_query($this->dbc, $query);
     while ($row = mysqli_fetch_array($result)) {
         $name = $row['name'];
         $score = $row['score'];
         $date = $row['date'];
         $output .= "<li>{$name} - {$score} - " . showDate($date) . "</li>\n";
     }
     $output .= "</ul>\n";
     return $output;
     $this->Disconnect();
 }
开发者ID:frsd1,项目名称:bth,代码行数:15,代码来源:DBCon.php


示例4: getBranch

 public function getBranch()
 {
     $branches = Branch::all();
     return Datatables::of($branches)->edit_column('image', function ($row) {
         if (!empty($row->image)) {
             return showImage($row->image, BRANCH_IMAGE . showDate($row->created, 1));
         }
     })->edit_column('status', function ($row) {
         return showSelectStatus($row->id, $row->status, 'Kacana.product.branch.setStatusBranch(' . $row->id . ', 1)', 'Kacana.product.branch.setStatusBranch(' . $row->id . ', 0)');
     })->edit_column('created', function ($row) {
         return showDate($row->created);
     })->edit_column('updated', function ($row) {
         return showDate($row->updated);
     })->add_column('action', function ($row) {
         return showActionButton('Kacana.product.branch.showEditBranchForm(' . $row->id . ')', 'Kacana.product.branch.removeBranch(' . $row->id . ')', true);
     })->make(true);
 }
开发者ID:kacana,项目名称:kacana.com,代码行数:17,代码来源:BranchController.php


示例5: getProduct

 /**
  * get products
  *
  * @return Response
  */
 public function getProduct()
 {
     $products = Product::all();
     return Datatables::of($products)->edit_column('image', function ($row) {
         if (!empty($row->image)) {
             return showImage($row->image, PRODUCT_IMAGE . $row->id);
         }
     })->edit_column('status', function ($row) {
         return showSelectStatus($row->id, $row->status, 'Kacana.product.setStatus(' . $row->id . ', 1)', 'Kacana.product.setStatus(' . $row->id . ', 0)');
     })->edit_column('created', function ($row) {
         return showDate($row->created);
     })->edit_column('updated', function ($row) {
         return showDate($row->updated);
     })->add_column('action', function ($row) {
         return showActionButton("/product/editProduct/" . $row->id, 'Kacana.product.removeProduct(' . $row->id . ')', false, false);
     })->make(true);
 }
开发者ID:kacana,项目名称:admin,代码行数:22,代码来源:ProductController.php


示例6: getUser

 public function getUser()
 {
     $users = User::all();
     return Datatables::of($users)->edit_column('image', function ($row) {
         if (!empty($row->image)) {
             return showImage($row->image, PRODUCT_IMAGE . $row->id);
         }
     })->edit_column('status', function ($row) {
         return showSelectStatus($row->id, $row->status, 'Kacana.user.setStatus(' . $row->id . ', 1)', 'Kacana.user.setStatus(' . $row->id . ', 0)');
     })->edit_column('created', function ($row) {
         return showDate($row->created);
     })->edit_column('updated', function ($row) {
         return showDate($row->updated);
     })->add_column('action', function ($row) {
         return showActionButton('Kacana.user.show(' . $row->id . ')', 'Kacana.product.branch.removeBranch(' . $row->id . ')', true);
     })->make(true);
 }
开发者ID:kacana,项目名称:admin,代码行数:17,代码来源:UserController.php


示例7: printHTMLStory2

function printHTMLStory2($story)
{
    //get domain
    $pattern = "^([a-zA-Z0-9]([a-zA-Z0-9\\-]{0,61}[a-zA-Z0-9])?\\.)+[a-zA-Z]{2,6}^";
    preg_match($pattern, $story->link, $matches);
    //var_dump($matches);
    echo "<div class=\"news-summary\" about=\"" . $story->href . "\">";
    echo "<div class=\"news-body\"><h3><a href=\"" . $story->link . "\">" . $story->title . "</a></h3>";
    echo "<p><em class=\"source\">" . $matches[0] . " &mdash; </em>";
    echo "<span>" . $story->description;
    echo "<a href=\"" . $story->href . "\" class=\"more\">More &hellip; </a></span>";
    echo "<span class=\"topic\">(<a href=\"http://www.digg.com/" . $story->topic_short_name . "\">" . $story->topic_name . "</a>)</span></p>";
    echo "<div class=\"news-details\">";
    echo " <a href=\"" . $story->href . "\" class=\"comments\">" . $story->comments . " Comments</a>";
    echo "<span class=\"user-info\">";
    echo "<a href=\"http://www.digg.com/users/" . $story->user_name . "\"><img src=\"" . $story->user_icon . "\" alt=\"" . $story->user_name . "\" class=\"user-photo\" height=\"16\" width=\"16\">" . $story->user_name . "</a> ";
    showDate($story->status, $story->submit_date, $story->promote_date);
    echo " </span></div></div>";
    echo "<ul class=\"news-digg\"><li class=\"digg-count\">";
    echo "<a href=\"" . $story->href . "\" >" . $story->diggs . " diggs</a></li></ul></div>\n";
}
开发者ID:achea,项目名称:linkhive,代码行数:21,代码来源:functions.php


示例8: elseif

                        <div class="grayBtn" onclick="libraly.del(\'' . $name . '\')">Удалить</div>
                    </div>
                    <div class="clear"></div>
                </div>
            </li>';
        }
        print '<ul class="ul tableList projectList">' . $prj . '</ul>';
    }
} elseif ($action == 'sLcat') {
    $read = my_fileBuld(ROOT_DIR . '/data/' . $is_logged . '/' . $idName . '/');
    if (count($read['file']) > 0) {
        foreach ($read['file'] as $name) {
            $p++;
            $p = $p > 2 ? 1 : $p;
            $size = FSize(ROOT_DIR . '/data/' . $is_logged . '/' . $idName . '/' . $name);
            $date = showDate(ROOT_DIR . '/data/' . $is_logged . '/' . $idName . '/' . $name);
            $name = str_replace(".data", '', $name);
            $prj .= '<li class="li_prj_' . $name . ' p_' . $p . '">
                <div class="lineB">
                    <img src="lib/images/lib_ico.png" class="left" />
                    <div class="left textPad" style="min-width: 100px; font-weight: bold">' . $name . '</div>
                    <div class="left grayColor textPad" style="min-width: 200px">' . $date . '</div>
                    <div class="left grayColor textPad">' . $size . '</div>
                    <div class="right">
                        <div class="grayBtn" style="margin-right: 10px" onclick="libraly.editCat(\'' . $name . '\',\'' . $idName . '\')">Редактировать</div>
                        <div class="grayBtn" onclick="libraly.delCat(\'' . $name . '\',\'' . $idName . '\')">Удалить</div>
                    </div>
                    <div class="clear"></div>
                </div>
            </li>';
        }
开发者ID:strangerandy,项目名称:raid,代码行数:31,代码来源:libraly.class.php


示例9: showDate

}
?>
</h2>
		<div id="image">
		  <a href="http://i.imgush.ru/<?php 
echo $this->img['image'] . '.' . $this->img['ext'];
?>
">
		   <img src="http://i.imgush.ru/<?php 
echo $this->img['image'] . '.' . $this->img['ext'];
?>
" />
		  </a>
	    </div>
	    <div id="under-image">
		  <span>Загружена <?php 
echo showDate(strtotime($this->img['date']));
?>
</span> |
		  <a href="http://imgush.ru/statis.php?add=gallery&name=<?php 
echo $this->img['image'];
?>
">Добавить</a>
		</div>
	
	  </div>
	
	  <div id="footer">
	  </div>
 </body>
</html>
开发者ID:iSkript,项目名称:Imgur-clone,代码行数:31,代码来源:viewimage.tpl.php


示例10: date

}
-->
</style></head>

<body>
<table width="1100" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td width="860" style="padding-bottom:10px;"><small>Print : <?php 
echo date('d M y, H:i:s');
?>
</small><br />
      <div style="font-size:22px; font-weight:bold;" align="center">REKAP DETAIL PENJUALA ITEM (<?php 
echo showDate($startdate);
?>
 s/d <?php 
echo showDate($enddate);
?>
)</div></td>
  </tr>
  
  <tr>
    <td><table width="1100" border="0" cellpadding="3" cellspacing="1" bgcolor="#CCCCCC">
      <tr>
        <td width="37" align="center" bgcolor="#EEEEEE">No.</td>
        <td width="79" align="center" bgcolor="#EEEEEE">Kode</td>
        <td width="120" align="center" bgcolor="#EEEEEE">Kategori</td>
        <td width="208" align="center" bgcolor="#EEEEEE">Nama Produk</td>
        <td width="173" align="center" bgcolor="#EEEEEE">Pilihan</td>
        <td width="89" align="center" bgcolor="#EEEEEE">Satuan</td>
        <td width="126" align="center" bgcolor="#EEEEEE">Harga</td>
        <td width="91" align="center" bgcolor="#EEEEEE">Diskon</td>
开发者ID:buruhsd,项目名称:customize-t-shirt,代码行数:31,代码来源:detailReport.php


示例11: showDate

// checks if the url has the module switch
if (isset($_GET['module'])) {
    if ($_GET['module'] != 'package' && $_GET['module'] != 'search' && $_GET['module'] != 'user') {
        $setmodule = "overview";
        // Default to overview
        $title = "<i class='icons8-calendar'></i><span id='date'>" . ($date = showDate() . "</span>");
    } else {
        $setmodule = $_GET['module'];
        // sets the module switch using the url
        $module = $_GET['module'];
        if ($module == 'search') {
            $title = "Lookup any package";
        }
    }
} else {
    if (!isset($_GET['module'])) {
        $setmodule = "overview";
        // Default to overview
        $title = "<i class='icons8-calendar'></i><span id='date'>" . ($date = showDate() . "</span>");
    }
}
if (isset($_GET['trackingnumber'])) {
    $title = "Viewing issue " . $_GET['trackingnumber'];
}
if ($_SERVER['REQUEST_URI'] == "/packagehero/includes/allpackages.php") {
    $title = "View a list of all current issues";
}
if ($_SERVER['REQUEST_URI'] == "/packagehero/includes/helpcenter.php") {
    $title = "Package Hero Help Center";
}
开发者ID:kenicenoel,项目名称:PackageHero,代码行数:30,代码来源:set-module.php


示例12: showDate

if (isset($error)) {
    ?>
			<div class="alert alert-info" role="alert"><?php 
    echo $error;
    ?>
</div>
			<?php 
} else {
    ?>
	    <?php 
    $date = $monday;
    for ($i = 1; $i <= count($diary); $i++) {
        ?>
	<h4 class="sidebar-header"><?php 
        echo $days[$i - 1] . " ";
        echo showDate($date);
        $date = date('Y-m-d', strtotime($date . ' + 1 day'));
        ?>
	</h4>
	<div class="panel panel-default">
	    <div class="table-responsive">
  	        <table class="table table-striped table-hover table-bordered">
			    <thead>
	    			<tr>
			    		<th style="width: 20%;">Предмет</th>
						<th style="width: 25%;">Оценки</th>
						<th style="width: 15%;">Домашнее задание</th>
						<th style="width: 25%;">Замечания</th>
						<th style="width: 15%;">Статус урока</th>
					</tr>
				</thead>
开发者ID:Nsity,项目名称:eschool,代码行数:31,代码来源:diaryview.php


示例13: number_format

        echo $r['no_order'];
        ?>
</td>
      <td valign="top"><a target="_blank" href="?p=edMember&id=<?php 
        echo $r['member_id'];
        ?>
"><?php 
        echo $r['member'];
        ?>
</a></td>
      <td align="right" valign="top"><?php 
        echo number_format($r['total_order']);
        ?>
</td>
      <td align="center" valign="top"><?php 
        echo showDate($r['tgl_order']);
        ?>
</td>
      <td align="center" valign="top"><?php 
        echo $r['status'] == 2 ? 'COMPLETED' : ($r['status'] == 1 ? 'PENDING' : 'CANCELLED');
        ?>
</td>
      <td align="center" valign="top">
      <a class="bTools" href="?p=addOrder&id=<?php 
        echo $r['id'];
        ?>
" title="Edit">E</a> 
      <a class="bTools" href="?p=delOrder&id=<?php 
        echo $r['id'];
        ?>
" title="Delete" onclick="return confirm('Hapus record <?php 
开发者ID:buruhsd,项目名称:customize-t-shirt,代码行数:31,代码来源:order.php


示例14: modelLink

        echo modelLink($item->make, $item->model);
        ?>
" title="<?php 
        echo filterText($item->make);
        ?>
 <?php 
        echo filterText($item->model);
        ?>
"><?php 
        echo filterText($item->make);
        ?>
 <?php 
        echo filterText($item->model);
        ?>
</a> <span><?php 
        echo showDate($item->time);
        ?>
</span></p>
                                    </div>
                                </div>
                            </div>
                        </li>
                        <!-- search results loop end //-->
                        <?php 
        $row += 1;
        ?>
                        <?php 
    }
    ?>
                    </ul>
                    <!-- search results end //-->
开发者ID:khalid9th,项目名称:ocAds,代码行数:31,代码来源:vSearch.php


示例15: getValueForJs

                ?>
",kg:"<?php 
                echo getValueForJs($r['masina']['kg']['VALUE']);
                ?>
",putere:"<?php 
                echo getValueForJs($r['masina']['putere']['VALUE']);
                ?>
",anfab:"<?php 
                echo getValueForJs($r['masina']['anfab']['VALUE']);
                ?>
"
,valoarenou:"<?php 
                echo getValueForJs($r['masina']['valoarenou']['VALUE']);
                ?>
",ITP:"<?php 
                echo getValueForJs(showDate($r['masina']['itp']['VALUE'], getLT('dateformat')));
                ?>
",ROVI:"<?php 
                echo getValueForJs(showDate($r['masina']['rovi']['VALUE'], getLT('dateformat')));
                ?>
"
,textbutton:"Salveaza datele"
					}</div>
				<div class="workstep"><div class="biglabel">Vehicul</div></div>
				<?php 
                include "extensions/info_vehicul.php";
            }
            return true;
        }
    }
}
开发者ID:jawedkhan,项目名称:rorca,代码行数:31,代码来源:process_offer_ws_client.php


示例16: array

        // читаем все комментарии для данного изображения
        $captions = $comments->find(array('image' => $image_name))->sort(array('uploaded' => -1))->limit(10);
        // считаем количество комментариев
        $total_captions = $comments->find(array('image' => $image_name))->count();
        // увеличиваем кол-во просмотров
        $images->update(array('image' => $image_name), array('$inc' => array('views' => 1)));
        $cursor = $images->find(array('gallery' => 1, 'date' => new MongoRegex("/{$date}/"), 'image' => array('$ne' => $image_name)))->sort(array('date' => $rnd))->limit(6);
        $tpl->image = $image;
        $tpl->cursor = $cursor;
        $tpl->captions = $captions;
        $tpl->total_captions = $total_captions;
        $tpl->comments = TRUE;
        $tpl->display('tpl/lookimage.tpl.php');
    } else {
        $tpl->display('tpl/404.tpl.php');
    }
} elseif (isset($_POST['from']) && isset($_POST['gotimage'])) {
    $from = $_POST['from'];
    $more_captions = $comments->find(array('image' => $_POST['gotimage']))->skip($from)->limit(10)->sort(array('uploaded' => -1));
    $ind = $from;
    foreach ($more_captions as $caption) {
        $ind++;
        echo "<div id=\"{$ind}\" class=\"caption\">";
        echo '<div class="author">';
        echo "<span style=\"color:#4E76C9;\">{$caption['username']}</span>";
        echo '<span>' . showDate($caption['uploaded']) . '</span>';
        echo '</div>';
        echo htmlspecialchars($caption['caption']);
        echo '</div>';
    }
}
开发者ID:iSkript,项目名称:Imgur-clone,代码行数:31,代码来源:gallery.php


示例17: showDate

        }
        ?>
								<td><input type="checkbox" name="messages[]" value="<?php 
        echo $message['USER_MESSAGE_ID'];
        ?>
"></td>
								<td class="col-md-5"><?php 
        echo $message['USER_NAME'];
        ?>
</td>
								<td class="col-md-5"><?php 
        echo $message['MESSAGE_TEXT'];
        ?>
</td>
								<td class="col-md-2"><?php 
        showDate($message['MESSAGE_DATE']);
        ?>
</td>
								</tr>
			<?php 
    }
}
?>
			            </tbody>
					</table>
				</div>
			</div>
			<?php 
echo $this->pagination->create_links();
?>
		</div>
开发者ID:Nsity,项目名称:eschool,代码行数:31,代码来源:messageview.php


示例18: while

    while ($r = mysql_fetch_array($results)) {
        ?>
    <tr class="<?php 
        echo $i % 2 == 0 ? 'odd' : '';
        ?>
">
      <td align="center"><?php 
        echo $i;
        ?>
</td>
      <td><?php 
        echo $r['nama_lengkap'];
        ?>
</td>
      <td align="center"><?php 
        echo showDate($r['tgl_lahir']);
        ?>
</td>
      <td><?php 
        echo $r['email'];
        ?>
</td>
      <td><?php 
        echo $r['telepon'];
        ?>
</td>
      <td align="center"><?php 
        echo $r['status'] == 1 ? 'Aktif' : 'Non Aktif';
        ?>
</td>
      <td align="center"><a class="bTools" href="?p=edMember&id=<?php 
开发者ID:buruhsd,项目名称:customize-t-shirt,代码行数:31,代码来源:member.php


示例19: showDateText

/**
 * @param $date
 * @param string $format
 * @return string
 */
function showDateText($date, $format = 'text')
{
    return showDate($date, $format);
}
开发者ID:birdiebel,项目名称:G2016,代码行数:9,代码来源:myDate.php


示例20: list

    list($gps_lat, $gps_lon) = explode(',', $_GET['gps']);
    if ($mysqli->connect_errno) {
        printf("Не удалось подключиться: %s\n", $mysqli->connect_error);
        exit;
    }
    //if ($_GET['netgps'] == 0)
    $mysqli->query("insert into yii2_rawdata (deviceid,latitude,longitude,bat,speed,alt,acc) values ('{$_GET['deviceid']}',{$gps_lat},{$gps_lon},{$_GET['bat']},{$_GET['speed']},{$_GET['alt']},{$_GET['acc']})");
}
if (isset($_GET['deviceid'], $_GET['getlastpoint'])) {
    $result = $mysqli->query("select * from yii2_rawdata where deviceid='{$_GET['deviceid']}' and alt <> 0 order by 'time' desc limit 1");
    $obj = $result->fetch_assoc();
    $result->close();
    $obj['latitude'] = floatval($obj['latitude']);
    $obj['longitude'] = floatval($obj['longitude']);
    $obj['speed'] = $obj['speed'] * 3.6;
    $obj['time'] = showDate(strtotime($obj['time']));
    //$obj['acc']=floatval($obj['acc']);
    echo json_encode($obj);
}
function showDate($date)
{
    $stf = 0;
    $cur_time = time();
    $diff = $cur_time - $date;
    $seconds = array('секунда', 'секунды', 'секунд');
    $minutes = array('минута', 'минуты', 'минут');
    $hours = array('час', 'часа', 'часов');
    $days = array('день', 'дня', 'дней');
    $weeks = array('неделя', 'недели', 'недель');
    $months = array('месяц', 'месяца', 'месяцев');
    $years = array('год', 'года', 'лет');
开发者ID:alliktm,项目名称:GPS-Tracker,代码行数:31,代码来源:api.php



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP showDialog函数代码示例发布时间:2022-05-24
下一篇:
PHP showDBError函数代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap