本文整理汇总了PHP中Format::db_date方法的典型用法代码示例。如果您正苦于以下问题:PHP Format::db_date方法的具体用法?PHP Format::db_date怎么用?PHP Format::db_date使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Format
的用法示例。
在下文中一共展示了Format::db_date方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
?>
"><?php
echo $row['users'];
?>
</a>
<?php
} else {
?>
0
<?php
}
?>
</td>
<td><?php
echo Format::db_date($row['created']);
?>
</td>
<td><?php
echo Format::db_datetime($row['updated']);
?>
</td>
</tr>
<?php
}
//end of while.
}
?>
<tfoot>
<tr>
<td colspan="7">
示例2: sprintf
value="<?php echo $row['id']; ?>" <?php echo $sel?'checked="checked"':''; ?> >
</td>
<td>
<a class="userPreview"
href="users.php?id=<?php echo $row['id']; ?>"><?php
echo Format::htmlchars($name); ?></a>
<?php
if ($row['tickets'])
echo sprintf('<i class="icon-fixed-width icon-file-text-alt"></i>
<small>(%d)</small>', $row['tickets']);
?>
</td>
<td><?php echo Format::htmlchars($row['email']); ?></td>
<td><?php echo $status; ?></td>
<td><?php echo Format::db_date($row['created']); ?></td>
</tr>
<?php
} //end of while.
endif; ?>
</tbody>
<tfoot>
<tr>
<td colspan="5">
<?php
if ($res && $num) {
?>
<?php echo __('Select'); ?>:
<a id="selectAll" href="#ckb"><?php echo __('All'); ?></a>
<a id="selectNone" href="#ckb"><?php echo __('None'); ?></a>
<a id="selectToggle" href="#ckb"><?php echo __('Toggle'); ?></a>
示例3:
?>
</a>
<?php
echo $row['attachments'] ? "<span class='Icon file'> </span>" : '';
?>
</td>
<td nowrap> <?php
echo Format::truncate($dept, 30);
?>
</td>
<td> <?php
echo Format::truncate($row['email'], 40);
?>
</td>
<td> <?php
echo Format::db_date($row['duedate'], 40);
?>
</td>
</tr>
<?php
$class = $class == 'row2' ? 'row1' : 'row2';
}
//end of while.
} else {
//not tickets found!!
?>
<tr class="<?php
echo $class;
?>
"><td colspan=7><b>NO tickets found.</b></td></tr>
示例4: sprintf
<h2>Frequently Asked Questions</h2>
</div>
<div style="float:right;text-align:right;padding-top:5px;padding-right:5px;"> </div>
<div class="clear"></div>
<br>
<div>
<strong><?php
echo $category->getName();
?>
</strong>
<span>(<?php
echo $category->isPublic() ? 'Public' : 'Internal';
?>
)</span>
<time>Last updated <?php
echo Format::db_date($category->getUpdateDate());
?>
</time>
</div>
<div class="cat-desc">
<?php
echo Format::display($category->getDescription());
?>
</div>
<?php
if ($thisstaff->canManageFAQ()) {
echo sprintf('<div class="cat-manage-bar"><a href="categories.php?id=%d" class="Icon editCategory">Edit Category</a>
<a href="categories.php" class="Icon deleteCategory">Delete Category</a>
<a href="faq.php?cid=%d&a=add" class="Icon newFAQ">Add New FAQ</a></div>', $category->getId(), $category->getId());
} else {
?>
示例5:
$subject = Format::truncate($row['subject'],40);
if(!strcasecmp($row['status'],'open') && !$row['isanswered'] && !$row['lock_id']) {
$tid=sprintf('<b>%s</b>',$tid);
//$subject=sprintf('<b>%s</b>',Format::truncate($row['subject'],40)); // Making the subject bold is too much for the eye
}
?>
<tr class="<?=$class?> " id="<?=$row['ticket_id']?>">
<?if($canDelete || $canClose) {?>
<td align="center" class="nohover">
<input type="checkbox" name="tids[]" value="<?=$row['ticket_id']?>" onClick="highLight(this.value,this.checked);">
</td>
<?}?>
<td align="center" title="<?=$row['email']?>" nowrap>
<a class="Icon <?=strtolower($row['source'])?>Ticket" title="<?=$row['source']?> Ticket: <?=$row['email']?>"
href="tickets.php?id=<?=$row['ticket_id']?>"><?=$tid?></a></td>
<td align="center" nowrap><?=Format::db_date($row['created'])?></td>
<td><a <?if($flag) { ?> class="Icon <?=$flag?>Ticket" title="<?=ucfirst($flag)?> Ticket" <?}?>
href="tickets.php?id=<?=$row['ticket_id']?>"><?=$subject?></a>
<?=$row['attachments']?"<span class='Icon file'> </span>":''?></td>
<td nowrap><?=Format::truncate($row['dept_name'],30)?></td>
<td class="nohover" align="center" style="background-color:<?=$row['priority_color']?>;"><?=$row['priority_desc']?></td>
<td nowrap><?=Format::truncate($row['name'],22,strpos($row['name'],'@'))?> </td>
</tr>
<?
$class = ($class =='row2') ?'row1':'row2';
} //end of while.
else: //not tickets found!! ?>
<tr class="<?=$class?>"><td colspan=8><b>Query returned 0 results.</b></td></tr>
<?
endif; ?>
</table>
示例6: _
?>
</a> </td>
<td><?php
echo Format::htmlchars($name);
?>
</td>
<td><?php
echo $row['client_organization'];
?>
</td>
<td><?php
echo $row['client_isactive'] ? _('Active') : '<b>' . _('Locked') . '</b>';
?>
</td>
<td><?php
echo Format::db_date($row['client_created']);
?>
</td>
<td><?php
echo Format::db_datetime($row['client_lastlogin']);
?>
</td>
</tr>
<?php
$class = $class == 'row2' ? 'row1' : 'row2';
}
//end of while.
} else {
?>
<tr class="<?php
示例7: _
?>
"><?php
echo $ticketID;
?>
</a></td>
<td align="center" nowrap><?php
echo Format::db_date($row['created']);
?>
</td>
<td align="center">
<?php
if ($row['status'] == 'closed') {
echo "<span class='Icon closedTicket' title='" . _('Closed on ') . Format::db_date($row['closed']) . "'> </span>";
} elseif ($row['isanswered'] && !strcasecmp($row['status'], 'open')) {
echo "<span class='Icon answeredTicket' title='" . _('Open - Answered on ') . Format::db_date($row['lastresponse']) . "'> </span>";
} else {
echo "<span class='Icon openTicket' title=" . _('Open') . "> </span>";
}
?>
</td>
<td nowrap> <?php
echo Format::truncate($dept, 30);
?>
</td>
<td>
<a href="tickets.php?id=<?php
echo $row['ticketID'];
?>
"><?php
echo $subject;
示例8:
$sel=false;
if(($uids && in_array($row['staff_id'],$uids)) or ($uID && $uID==$row['staff_id'])){
$class="$class highlight";
$sel=true;
}
$name=ucfirst($row['firstname'].' '.$row['lastname']);
?>
<tr class="<?=$class?>" id="<?=$row['staff_id']?>">
<td width=7px>
<input type="checkbox" name="uids[]" value="<?=$row['staff_id']?>" <?=$sel?'checked':''?> onClick="highLight(this.value,this.checked);">
<td><a href="admin.php?t=staff&id=<?=$row['staff_id']?>"><?=Format::htmlchars($name)?></a> </td>
<td><?=$row['username']?></td>
<td><?=$row['isactive']?'Active':'<b>Locked</b>'?> <?=$row['onvacation']?'(<i>vacation</i>)':''?></td>
<td><a href="admin.php?t=grp&id=<?=$row['group_id']?>"><?=Format::htmlchars($row['group_name'])?></a></td>
<td><a href="admin.php?t=dept&id=<?=$row['dept_id']?>"><?=Format::htmlchars($row['dept_name'])?></a></td>
<td><?=Format::db_date($row['created'])?></td>
<td><?=Format::db_datetime($row['lastlogin'])?> </td>
</tr>
<?
$class = ($class =='row2') ?'row1':'row2';
} //end of while.
else: ?>
<tr class="<?=$class?>"><td colspan=8><b>Query returned 0 results</b></td></tr>
<?
endif; ?>
</table>
</td></tr>
<?
if(db_num_rows($users)>0): //Show options..
?>
<tr><td>
示例9: while
if($tickets_res && ($num=db_num_rows($tickets_res))):
$defaultDept=Dept::getDefaultDeptName();
while ($row = db_fetch_array($tickets_res)) {
$dept=$row['ispublic']?$row['dept_name']:$defaultDept; //Don't show hidden/non-public depts.
$subject=Format::htmlchars(Format::truncate($row['subject'],40));
$ticketID=$row['ticketID'];
if($row['isanswered'] && !strcasecmp($row['status'],'open')) {
$subject="<b>$subject</b>";
$ticketID="<b>$ticketID</b>";
}
?>
<tr class="<?=$class?> " id="<?=$row['ticketID']?>">
<td align="center" title="<?=$row['email']?>" nowrap>
<a class="Icon <?=strtolower($row['source'])?>Ticket" title="<?=$row['email']?>" href="view.php?id=<?=$row['ticketID']?>">
<?=$ticketID?></a></td>
<td nowrap> <?=Format::db_date($row['created'])?></td>
<td> <?=ucfirst($row['status'])?></td>
<td> <a href="view.php?id=<?=$row['ticketID']?>"><?=$subject?></a>
<?=$row['attachments']?"<span class='Icon file'> </span>":''?></td>
<td nowrap> <?=Format::truncate($dept,30)?></td>
<td> <?=Format::truncate($row['email'],40)?></td>
</tr>
<?
$class = ($class =='row2') ?'row1':'row2';
} //end of while.
else: //not tickets found!! ?>
<tr class="<?=$class?>"><td colspan=7><b>NO tickets found.</b></td></tr>
<?
endif; ?>
</table>
</td></tr>