Exemple #1
0
function get_other_test()
{
    global $_G;
    pload('F:spider');
    $url = format_url($_GET['url']);
    $args['from_get_type'] = format_url($_GET['from_get_type']);
    $args['author_get_type'] = format_url($_GET['author_get_type']);
    $args['dateline_get_type'] = format_url($_GET['dateline_get_type']);
    $args['from_get_rules'] = format_url($_GET['from_get_rules']);
    $args['author_get_rules'] = format_url($_GET['author_get_rules']);
    $args['dateline_get_rules'] = format_url($_GET['dateline_get_rules']);
    $login_cookie = format_cookie($_GET['login_cookie']);
    $contents = get_contents($url, array('cookie' => $login_cookie));
    $data = get_other_info($contents, $args);
    $show_time = str_format_time($data['article_dateline']);
    $show_time = $show_time ? dgmdate($show_time) : '';
    if (!$data) {
        $output = milu_lang('no_get_info');
    } else {
        $output = '<table class="tb tb2 "><tbody><tr class="header"><th width="51">' . milu_lang('field_name') . '</th><th width="220">' . milu_lang('the_get_info') . '</th><th width="80">' . milu_lang('trun_info') . '</th></tr>
		
		<tr class="td24"><td class="td25">' . milu_lang('article_from') . '</td><td class="td24">' . $data['from'] . '</td><td>' . milu_lang('no_turn') . '</td></tr>
		<tr class="td24"><td class="td25">' . milu_lang('old_author') . '</td><td class="td24">' . $data['author'] . '</td><td>' . milu_lang('no_turn') . '</td></tr>
		<tr class="td24"><td class="td25">' . milu_lang('public_time') . '</td><td class="td24">' . $data['article_dateline'] . '</td><td>' . $show_time . '</td></tr>
		
		</tr></tbody></table>';
        if ($args['dateline_get_rules']) {
            $output .= milu_lang('get_other_notice');
        }
    }
    show_pick_window(milu_lang('get_other_show'), $output, array('w' => 645, 'h' => '460', 'f' => 1));
}
Exemple #2
0
 function get_article_other($contents)
 {
     if ($this->p_arr['is_get_other'] != 1) {
         return array();
     }
     $data = (array) get_other_info($contents, $this->p_arr);
     $data['article_dateline'] = str_format_time($data['article_dateline']);
     return $data;
 }