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


PHP print_date函数代码示例

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


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

示例1: print_versions

/**
 * @param $edit_page
 * @param $obsolete_flag
 */
function print_versions($edit_page, $obsolete_flag)
{
    $specmanagement_database_api = new specmanagement_database_api();
    $specmanagement_print_api = new specmanagement_print_api();
    $obsolote = false;
    if ($obsolete_flag) {
        $obsolote = null;
    }
    if ($edit_page) {
        $versions = version_get_all_rows_with_subs(helper_get_current_project(), null, null);
    } else {
        $versions = version_get_all_rows_with_subs(helper_get_current_project(), null, $obsolote);
    }
    for ($version_index = 0; $version_index < count($versions); $version_index++) {
        $version = $versions[$version_index];
        $current_type = $specmanagement_database_api->get_type_string($specmanagement_database_api->get_type_by_version($version['id']));
        $specmanagement_print_api->printRow();
        echo '<input type="hidden" name="version_ids[]" value="' . $version['id'] . '"/>';
        print_name($edit_page, $version);
        print_released($edit_page, $version_index, $version);
        print_obsolete($edit_page, $version_index, $version);
        print_date($edit_page, $version);
        print_type($edit_page, $current_type, $version);
        print_description($edit_page, $version);
        print_action($edit_page, $version);
        echo '</tr>';
    }
}
开发者ID:Cre-ator,项目名称:Whiteboard.SpecificationManagement-Plugin,代码行数:32,代码来源:manage_versions.php

示例2: extract_data

function extract_data($value)
{
    $htmlvalue = str_get_html($value);
    //print $htmlvalue;
    $link = $htmlvalue->find('li[class="first last"] a', 0);
    $title = $htmlvalue->find('li[class="first last"] a', 0);
    $description = $htmlvalue->find('li[class="first last"] a', 0);
    $date = $htmlvalue->find('span[class="date-display-single"]', 0);
    $processdate = substr($date->plaintext, -10);
    //print $link->href. "\n";
    //print $title->plaintext. "\n";
    //print $description->plaintext. "\n";
    $when = date_create_from_format('d/m/Y', $processdate);
    print_date($when);
    $data = array('link' => $link->href, 'title' => $title->plaintext, 'description' => $description->plaintext, 'date' => $when);
    scraperwiki::save(array('title'), $data);
}
开发者ID:flyeven,项目名称:scraperwiki-scraper-vault,代码行数:17,代码来源:aagbi_totw_element_browse.php

示例3: count

if (count($blank_invoices)) {
    ?>
	<h2>Blank invoices found</h2>
	We found the following <?php 
    echo count($blank_invoices);
    ?>
 blank invoices that were created from a recent "Subscription" bug:
	<ul>
		<?php 
    foreach ($blank_invoices as $blank_invoice) {
        ?>
		<li><?php 
        echo module_invoice::link_open($blank_invoice['invoice_id'], true);
        ?>
 created on <?php 
        echo print_date($blank_invoice['date_created']);
        ?>
</li>
		<?php 
    }
    ?>
	</ul>
	You can remove all these invoices manually, or click the button below to remove them automatically.
	<form action="" method="post">
		<input type="hidden" name="remove_duplicates" value="yes">
		<input type="submit" value="Remove these <?php 
    echo count($blank_invoices);
    ?>
 invoices">
	</form>
	<?php 
开发者ID:sgh1986915,项目名称:php-crm,代码行数:31,代码来源:invoice_settings.php

示例4: pic_location

?>
">
                    <img class="img-responsive" src="<?php 
pic_location(11);
?>
" alt="">
                </a>
                <h3><a href="<?php 
pic_location(11);
?>
"><?php 
print_name(11);
?>
</a></h3>
                <p><?php 
print_date(11);
?>
</p>
            </div>
        </div>
        <!-- /.row -->

       

        <!-- Footer -->
        <footer>
            <div class="row">
                <div class="col-lg-12">
                    <p>Copyright &copy; Aaron Wisner 2014 aaronwisner@gmail.com</p>
                </div>
            </div>
开发者ID:cgvarela,项目名称:parallella-examples,代码行数:31,代码来源:index.php

示例5: helper_get_tab_index

    } else {
        echo '<select ', helper_get_tab_index(), ' name="user_id">';
        print_user_option_list($t_tag_row['user_id'], ALL_PROJECTS, config_get('tag_create_threshold'));
        echo '</select>';
    }
} else {
    echo user_get_name($t_tag_row['user_id']);
}
?>
</td>
	<td><?php 
echo print_date(config_get('normal_date_format'), db_unixtimestamp($t_tag_row['date_created']));
?>
 </td>
	<td><?php 
echo print_date(config_get('normal_date_format'), db_unixtimestamp($t_tag_row['date_updated']));
?>
 </td>
</tr>

<!-- spacer -->
<tr class="spacer">
	<td colspan="5"></td>
</tr>

<!-- Description -->
<tr <?php 
echo helper_alternate_class();
?>
>
	<td class="category"><?php 
开发者ID:jin255ff,项目名称:company_website,代码行数:31,代码来源:tag_update_page.php

示例6: _l

        echo _l('(%s out of %s tickets)', ordinal($ticket['position']), $ticket['total_pending']);
    }
    ?>

	                    <input type="hidden" name="status_id" value="<?php 
    echo $ticket['status_id'];
    ?>
">
						<?php 
}))));
if ($ticket['last_message_timestamp']) {
    $fieldset_data['elements'][] = array('title' => _l('Date/Time'), 'fields' => array(function () use($ticket, $limit_time) {
        if ($ticket['last_message_timestamp'] < $limit_time) {
            echo '<span class="important">';
        }
        echo print_date($ticket['last_message_timestamp'], true);
        // how many days ago was this?
        echo ' ';
        $days = ceil(($ticket['last_message_timestamp'] + 1 - time()) / 86400);
        if (abs($days) == 0) {
            _e('(today)');
        } else {
            _e(' (%s days ago)', abs($days));
        }
        if ($ticket['last_message_timestamp'] < $limit_time) {
            echo '</span>';
        }
    }));
}
$fieldset_data['elements'][] = array('title' => _l('Subject'), 'fields' => array(function () use($ticket) {
    if ($ticket['subject']) {
开发者ID:sgh1986915,项目名称:php-crm,代码行数:31,代码来源:ticket_admin_edit.php

示例7: get_enum_element

		<?php 
echo get_enum_element('reproducibility', $t_bug->reproducibility);
?>
	</td>

	<!-- Date Submitted -->
	<td>
		<?php 
print_date(config_get('normal_date_format'), $t_bug->date_submitted);
?>
	</td>

	<!-- Date Updated -->
	<td>
		<?php 
print_date(config_get('normal_date_format'), $t_bug->last_updated);
?>
	</td>

</tr>


<!-- spacer -->
<tr class="spacer">
	<td colspan="6"></td>
</tr>


<tr <?php 
echo helper_alternate_class();
?>
开发者ID:amjadtbssm,项目名称:website,代码行数:31,代码来源:bug_view_advanced_page.php

示例8: array

}, 'cell_class' => 'row_action');
$columns['newsletter_from'] = array('title' => 'Sent From', 'callback' => function ($newsletter) {
    ?>
 &lt;<?php 
    echo htmlspecialchars($newsletter['from_name']);
    ?>
&gt; <?php 
    echo htmlspecialchars($newsletter['from_email']);
    ?>
 <?php 
});
$columns['newsletter_date'] = array('title' => 'Sent Date', 'callback' => function ($newsletter) {
    if (!$newsletter['send_data'] || !$newsletter['send_data']['finish_time']) {
        echo _l('Never sent');
    } else {
        echo print_date($newsletter['send_data']['finish_time'], true);
    }
});
$columns['newsletter_to'] = array('title' => 'Sent To', 'callback' => function ($newsletter) {
    if ($newsletter['send_data']) {
        echo _l('%s of %s', (int) $newsletter['send_data']['total_sent_count'], (int) $newsletter['send_data']['total_member_count']);
    }
});
$columns['newsletter_views'] = array('title' => 'Views', 'callback' => function ($newsletter) {
    if ($newsletter['send_data']) {
        echo (int) $newsletter['send_data']['total_open_count'];
        echo ' ';
        if ($newsletter['send_data']['total_member_count'] > 0) {
            echo '(' . (int) ($newsletter['send_data']['total_open_count'] / $newsletter['send_data']['total_member_count'] * 100) . '%)';
        }
    }
开发者ID:sgh1986915,项目名称:php-crm,代码行数:31,代码来源:newsletter_list.php

示例9: html_set_rss_link

    html_set_rss_link($t_rss_link);
}
html_page_top1();
html_page_top2();
if (!current_user_is_anonymous()) {
    echo '<div class="quick-summary-left">';
    echo lang_get('open_and_assigned_to_me') . ': ';
    echo '<a class="subtle" href="view_all_set.php?type=1&amp;handler_id=' . auth_get_current_user_id() . '&amp;hide_status=' . RESOLVED . '">' . current_user_get_assigned_open_bug_count() . '</a>';
    echo '</div>';
    echo '<div class="quick-summary-right">';
    echo lang_get('open_and_reported_to_me') . ': ';
    echo '<a class="subtle" href="view_all_set.php?type=1&amp;reporter_id=' . auth_get_current_user_id() . '&amp;hide_status=' . RESOLVED . '">' . current_user_get_reported_open_bug_count() . '</a>';
    echo '</div>';
    echo '<div class="quick-summary-left">';
    echo lang_get('last_visit') . ': ';
    echo print_date(config_get('normal_date_format'), db_unixtimestamp(current_user_get_field('last_visit')));
    echo '</div>';
}
echo '<br />';
echo '<br />';
echo '<br />';
$t_news_rows = news_get_limited_rows($f_offset, $t_project_id);
$t_news_count = count($t_news_rows);
# Loop through results
for ($i = 0; $i < $t_news_count; $i++) {
    $t_row = $t_news_rows[$i];
    # only show VS_PRIVATE posts to configured threshold and above
    if (VS_PRIVATE == $t_row['view_state'] && !access_has_project_level(config_get('private_news_threshold'))) {
        continue;
    }
    print_news_entry_from_row($t_row);
开发者ID:renemilk,项目名称:spring-website,代码行数:31,代码来源:main_page.php

示例10: print_heading

                <?php 
print_heading(array('type' => 'h3', 'title' => 'Send Statistics'));
?>
                <table class="tableclass tableclass_form tableclass_full">
                    <tbody>
                    <tr>
                        <th class="width1"><?php 
_e('Start sending');
?>
</th>
                        <td>
                            <?php 
if ($start_time <= time()) {
    _e('Now');
} else {
    echo print_date($start_time, true);
}
?>
                        </td>
                    </tr>
                    <tr>
                        <th><?php 
_e('Sent To');
?>
</th>
                        <td id="sent_to">
                            <?php 
echo _l('%s of %s', (int) $send['total_sent_count'], (int) $send['total_member_count']);
?>
                        </td>
                    </tr>
开发者ID:sgh1986915,项目名称:php-crm,代码行数:31,代码来源:newsletter_queue_watch.php

示例11: array

    </div>
    <?php 
}
if ($job_data && isset($job_data['job_discussion']) && $job_data['job_discussion'] == 2) {
    // disabled & shown.
    return;
}
if ($allow_new) {
    ?>
<div class="task_job_discussion_comments">
    <div class="info">
        <?php 
    echo $current_user_id ? module_user::link_open($current_user_id, true, array(), true) : 'Unknown';
    ?>
        <?php 
    echo print_date(time(), true);
    ?>
    </div>
    <textarea rows="4" cols="30" name="new_comment"></textarea> <br/>
    <input type="button" name="add" value="<?php 
    _e('Add Comment');
    ?>
" class="task_job_discussion_add small_button" data-jobid="<?php 
    echo $job_id;
    ?>
" data-taskid="<?php 
    echo $task_id;
    ?>
">
    <?php 
    $send_to_customer_ids = array();
开发者ID:sgh1986915,项目名称:php-crm,代码行数:31,代码来源:comment_list.php

示例12: strtotime

        ?>
">
                <?php 
    }
    ?>
            <?php 
    $next_due = strtotime($recurring['next_due_date']);
    if (!$recurring['next_due_date'] || $recurring['next_due_date'] == '0000-00-00') {
        echo _l('(recurring finished)');
    } else {
        if ($next_due < time()) {
            echo '<span class="important">';
            echo print_date($recurring['next_due_date']);
            echo '</span>';
        } else {
            echo print_date($recurring['next_due_date']);
        }
    }
    //if($show_record_button){
    $days = ceil(($next_due + 1 - time()) / 86400);
    if (abs($days) == 0) {
        _e('(today)');
    } else {
        _e(' (%s days)', $days);
    }
    //}
    ?>
                <?php 
    if ($show_record_button) {
        ?>
                </a>
开发者ID:sgh1986915,项目名称:php-crm,代码行数:31,代码来源:recurring_list.php

示例13: foreach

	<th class="sf_admin_text sf_admin_list_th ui-state-default ui-th-column"></th>
	<th class="sf_admin_text sf_admin_list_th ui-state-default ui-th-column">Fecha</th>
	<th class="sf_admin_text sf_admin_list_th ui-state-default ui-th-column">Monto</th>
</tr>
</thead>  
  <?php 
$_LIST_SIZE = 10;
foreach ($client->getMembershipFees() as $membership) {
    ?>
		<tr class="sf_admin_row ui-widget-content odd">
			<td class="sf_admin_text sf_admin_list_td"> 
  					<img alt="Checked" title="Checked" src="/sfDoctrinePlugin/images/tick.png">
			</td>
			<td class="sf_admin_text sf_admin_list_td">
				<?php 
    echo print_date($membership->getDate(), 'd-m-Y');
    ?>
			</td>
			<td class="sf_admin_text sf_admin_list_td">
			<?php 
    echo $membership->getAmount();
    ?>
			</td>
		</tr>
   <?php 
    $_LIST_SIZE--;
    if ($_LIST_SIZE <= 0) {
        break;
    }
}
?>
开发者ID:omarcl,项目名称:training-spot,代码行数:31,代码来源:_payments.php

示例14: get_form_element

    function get_form_element($element, $viewing_revision = false, $data_record = array())
    {
        $has_write_access = !$viewing_revision;
        // convert our data field to an element.
        $element['name'] = isset($element['name']) && !empty($element['name']) ? $element['name'] : 'data_field[' . $element['data_field_id'] . ']';
        $element['id'] = 'data_field_' . $element['data_field_id'] . '';
        $element['type'] = $element['field_type'];
        if (!isset($element['value'])) {
            $element['value'] = '';
        }
        if (!$has_write_access) {
            //$element['disabled'] = 'disabled';
            $element['class'] = 'data_field_view';
        }
        $highlight = false;
        $this->ajax_edit = false;
        $input_name = $element['name'];
        if (!$input_name) {
            return false;
        }
        if (isset($element['id']) && $element['id']) {
            $input_id = $element['id'];
        } else {
            $element['id'] = $input_name;
            $input_id = $input_name;
        }
        //if(!$value && isset($_REQUEST[$input_name]))$value = $_REQUEST[$input_name];
        if (!$element['value']) {
            $element['value'] = $element['default'];
        }
        if (!is_array($element['value'])) {
            //$value=htmlspecialchars($value);
        }
        if (!isset($element['class'])) {
            $element['class'] = '';
        }
        $attr = $attr_other = '';
        if ($has_write_access) {
            if ($element['type'] == 'radio' || $element['type'] == 'checkbox_list') {
                // hacky!
                if ($element['required']) {
                    $attr_other .= ' class="form_field form_field_required"';
                } else {
                    $attr_other .= ' class="form_field"';
                }
            } else {
                $element['class'] .= " form_field";
                if ($element['required']) {
                    $element['class'] .= " form_field_required";
                }
            }
            switch ($element['type']) {
                case 'date':
                    $element['class'] .= " date_field";
                    if (!isset($element['size']) || !$element['size']) {
                        $element['size'] = 8;
                    }
                    if (strtolower($element['value']) == 'now') {
                        $element['value'] = print_date(time());
                    }
                    break;
                case 'datetime':
                    $element['class'] .= " date_time_field";
                    if (!isset($element['size']) || !$element['size']) {
                        $element['size'] = 12;
                    }
                    if (strtolower($element['value']) == 'now') {
                        $element['value'] = print_date(time(), true);
                    }
                    break;
            }
        }
        switch ($element['type']) {
            case 'checkbox_list':
            case 'radio':
                $element['attributes'] = array();
                foreach (explode("\n", trim($element['field_data'])) as $line) {
                    $line = trim($line);
                    if (preg_match('/^attributes=/', $line)) {
                        $line = preg_replace('/^attributes=/', '', $line);
                        $element['attributes'] = explode("|", $line);
                        break;
                    }
                }
                break;
            case 'select':
                if (!isset($element['attributes']) || !is_array($element['attributes']) || !count($element['attributes'])) {
                    $element['attributes'] = array();
                    foreach (explode("\n", trim($element['field_data'])) as $line) {
                        $line = trim($line);
                        if (preg_match('/^attributes=/', $line)) {
                            $line = preg_replace('/^attributes=/', '', $line);
                            if (preg_match('#hook:([\\w_]+)$#', $line, $matches)) {
                                // see if we get anything back from this hook.
                                $attributes = array();
                                $attributes = hook_filter_var($matches[1], $attributes, $element);
                                if (is_array($attributes)) {
                                    $element['attributes'] = $attributes;
                                } else {
                                    $element['attributes'] = array('Unable to call hook: ' . $matches[1]);
//.........这里部分代码省略.........
开发者ID:sgh1986915,项目名称:php-crm,代码行数:101,代码来源:data.php

示例15: print_date

                                        <?php 
                echo $alert['warning'] ? '<span class="important">' : '';
                ?>
                                        <?php 
                echo $alert['days'];
                ?>
                                        <?php 
                echo $alert['warning'] ? '</span>' : '';
                ?>
                                    </td>
                                <td width="16%">
                                    <?php 
                echo $alert['warning'] ? '<span class="important">' : '';
                ?>
                                    <?php 
                echo print_date($alert['date']);
                ?>
                                    <?php 
                echo $alert['warning'] ? '</span>' : '';
                ?>
                                </td>
                                <?php 
                if (isset($alert['hide_key']) && $alert['hide_key']) {
                    ?>
                                <td width="10">
                                    <a href="#" class="ui-corner-all ui-icon ui-icon-trash" onclick="return hide_item('<?php 
                    echo $alert['hide_key'];
                    ?>
');">[x]</a>
                                </td>
                                <?php 
开发者ID:sgh1986915,项目名称:php-crm,代码行数:31,代码来源:dashboard_alerts.php


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