Exemple #1
0
function update_search_content(&$a)
{
    $profile_uid = intval($_GET['p']);
    if (!$profile_uid) {
        $profile_uid = -1;
    }
    $load = argc() > 1 && argv(1) == 'load' ? 1 : 0;
    header("Content-type: text/html");
    echo "<!DOCTYPE html><html><body>\r\n";
    /**
     * We can remove this hack once Internet Explorer recognises HTML5 natively
     */
    echo $_GET['msie'] == 1 ? '<div>' : '<section>';
    /**
     *
     * Grab the page inner contents by calling the content function from the profile module directly, 
     * but move any image src attributes to another attribute name. This is because 
     * some browsers will prefetch all the images for the page even if we don't need them.
     * The only ones we need to fetch are those for new page additions, which we'll discover
     * on the client side and then swap the image back.
     *
     */
    $text = search_content($a, $profile_uid, $load);
    $pattern = "/<img([^>]*) src=\"([^\"]*)\"/";
    $replace = "<img\${1} dst=\"\${2}\"";
    //	$text = preg_replace($pattern, $replace, $text);
    /*
    	if(! $load) {
    		$replace = '<br />' . t('[Embedded content - reload page to view]') . '<br />';
    		$pattern = "/<\s*audio[^>]*>(.*?)<\s*\/\s*audio>/i";
    		$text = preg_replace($pattern, $replace, $text);
    		$pattern = "/<\s*video[^>]*>(.*?)<\s*\/\s*video>/i";
    		$text = preg_replace($pattern, $replace, $text);
    		$pattern = "/<\s*embed[^>]*>(.*?)<\s*\/\s*embed>/i";
    		$text = preg_replace($pattern, $replace, $text);
        	$pattern = "/<\s*iframe[^>]*>(.*?)<\s*\/\s*iframe>/i";
        	$text = preg_replace($pattern, $replace, $text);
    	}
    */
    /**
     * reportedly some versions of MSIE don't handle tabs in XMLHttpRequest documents very well
     */
    echo str_replace("\t", '       ', $text);
    echo $_GET['msie'] == 1 ? '</div>' : '</section>';
    echo "</body></html>\r\n";
    killme();
}
Exemple #2
0
<?php

include_once dirname(__FILE__) . '/../frame.php';
$key = $_GET['key'];
$db = get_db();
if (strlen($key) > 100) {
    redirect('error.html');
    die;
}
if (empty($key)) {
    $count = 0;
    $page_record_count = 0;
} else {
    $record = search_content($key);
    $count = count($record);
}
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<meta http-equiv=Content-Type content="text/html; charset=utf-8">
	<meta http-equiv=Content-Language content=zh-cn>
	<title><?php 
echo $key;
?>
_新闻检索_福布斯中文网</title>
	<?php 
use_jquery();
js_include_tag('public', 'right', 'search/news_highlight.js');
css_include_tag('news', 'public', 'right_inc');
?>
Exemple #3
0
<?php

include_once dirname(__FILE__) . '/../frame.php';
$key = $_GET['key'];
$db = get_db();
if (strlen($key) > 100) {
    redirect('error.html');
    die;
}
if (empty($key)) {
    $count = 0;
    $page_record_count = 0;
} else {
    //		$record = search_content($key,'eb_assistant');
    $record = search_content($key, 'eb_news');
    //+ search_content($key,'eb_assistant');
    $count = count($record);
}
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
<html>
<head>
	<meta http-equiv=Content-Type content="text/html; charset=utf-8">
	<meta http-equiv=Content-Language content=zh-cn>
	<title><?php 
echo $key;
?>
_新闻检索_网趣宝贝</title>
	<?php 
$result_key = $key;
use_jquery();
Exemple #4
0
<?php

error_reporting(E_ALL ^ E_NOTICE);
include "global.php";
include "../sources/userMatrixClass.php";
$cp->header();
$links = '<a href="rcm_matrix.php?do=search">Search</a>';
do_module_header('Relational Content Matrix', $links);
switch ($_REQUEST['do']) {
    case 'search':
        search_content();
        break;
    case 'search2':
        search2();
        break;
    case 'viewmatrix':
        viewmatrix();
        break;
    case 'create':
        create_new();
        break;
    case 'create2':
        create_confirm();
        break;
    case 'delete_resource':
        delete_resource();
        break;
}
function viewmatrix()
{
    global $db;
Exemple #5
0
    echo ' selected="selected"';
}
?>
>已选择</option>
			</select>
			<input type="button" value="搜索" id="search_button" >	
	</div>

	<div id=itable style="width:960px;">
	<table cellspacing=1 border="0" style="width:950px;">
		<tr class="itable_title">
			<td width="10%">选择</td><td width="50%">短标题</td><td width="20%">发表时间</td><td width="20%">所属类别</td>
		</tr>
		<?php 
$subject = new table_class("eb_news");
$items = search_content($_REQUEST['key'], 'eb_news', $conditions, 25, $order);
$count_record = count($items);
//--------------------
for ($i = 0; $i < $count_record; $i++) {
    ?>
		<tr class=tr3>
					<td><input type="checkbox" id="<?php 
    echo $items[$i]->id;
    ?>
" value="<?php 
    echo $items[$i]->id;
    ?>
" name="subject" style="width:12px;"></td>
					<td style="text-indent:24px; text-align:left;"><?php 
    echo strip_tags($items[$i]->title);
    ?>
Exemple #6
0
" class="post group">

			<h3><a href="<?php 
        the_permalink();
        ?>
"><?php 
        the_title();
        ?>
</a></h3>

			<?php 
        get_template_part('inc/', 'meta');
        ?>

			<?php 
        echo search_content(get_the_excerpt());
        ?>

			<?php 
        the_tags('<p class="tags">Tags: ', ', ', '<p/>');
        ?>

		</article><!-- post-ID -->
		<hr>

	<?php 
    }
    ?>

	<?php 
    get_template_part('inc/', 'nav');