Vergleich inc/functions_search.php - 1.2.1 - 1.2.5

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 6Zeile 6
 * Website: http://www.mybboard.com
* License: http://www.mybboard.com/eula.html
*

 * Website: http://www.mybboard.com
* License: http://www.mybboard.com/eula.html
*

 * $Id: functions_search.php 2281 2006-09-27 12:24:50Z chris $

 * $Id: functions_search.php 2299 2006-09-30 17:22:05Z Tikitiki $

 */

/**

 */

/**

Zeile 420Zeile 420
		$datecut .= "'$datelimit'";
$post_datecut = " AND p.dateline $datecut";
$thread_datecut = " AND t.dateline $datecut";

		$datecut .= "'$datelimit'";
$post_datecut = " AND p.dateline $datecut";
$thread_datecut = " AND t.dateline $datecut";

 
	}

$thread_replycut = "";
if($search['numreplies'] != "" && $search['findthreadst'])
{
if(intval($search['findthreadst']) == 1)
{
$thread_replycut = " AND t.replies >= '".intval($search['numreplies'])."'";
}
else
{
$thread_replycut = " AND t.replies <= '".intval($search['numreplies'])."'";
}

	}

$forumin = "";

	}

$forumin = "";

Zeile 450Zeile 463
					if(count($fidlist) > 1)
{
$forumin = " AND t.fid IN (".implode(",", $fidlist).")";

					if(count($fidlist) > 1)
{
$forumin = " AND t.fid IN (".implode(",", $fidlist).")";

					}

					}

				}
}
}

				}
}
}

Zeile 473Zeile 486
	if($search['postthread'] == 1)
{
$searchtype = "titles";

	if($search['postthread'] == 1)
{
$searchtype = "titles";

		$query = $db->query("
SELECT t.tid, t.firstpost
FROM ".TABLE_PREFIX."threads t
WHERE 1=1 $thread_datecut $forumin $thread_usersql $permsql AND t.visible>0 AND t.closed NOT LIKE 'moved|%' $subject_lookin
");
while($thread = $db->fetch_array($query))
{
$threads[$thread['tid']] = $thread['tid'];
if($thread['firstpost'])

		$query = $db->query("
SELECT t.tid, t.firstpost
FROM ".TABLE_PREFIX."threads t
WHERE 1=1 $thread_datecut $thread_replycut $forumin $thread_usersql $permsql AND t.visible>0 AND t.closed NOT LIKE 'moved|%' $subject_lookin
");
while($thread = $db->fetch_array($query))
{
$threads[$thread['tid']] = $thread['tid'];
if($thread['firstpost'])

			{
$posts[$thread['tid']] = $thread['firstpost'];
}

			{
$posts[$thread['tid']] = $thread['firstpost'];
}

Zeile 490Zeile 503
			SELECT p.pid, p.tid
FROM ".TABLE_PREFIX."posts p
LEFT JOIN ".TABLE_PREFIX."threads t ON (t.tid=p.tid)

			SELECT p.pid, p.tid
FROM ".TABLE_PREFIX."posts p
LEFT JOIN ".TABLE_PREFIX."threads t ON (t.tid=p.tid)

			WHERE 1=1 $post_datecut $forumin $post_usersql $permsql AND p.visible>0 AND t.visible>0 AND t.closed NOT LIKE 'moved|%' $message_lookin

			WHERE 1=1 $post_datecut $thread_replycut $forumin $post_usersql $permsql AND p.visible>0 AND t.visible>0 AND t.closed NOT LIKE 'moved|%' $message_lookin

		");
while($post = $db->fetch_array($query))
{

		");
while($post = $db->fetch_array($query))
{

Zeile 512Zeile 525
		$query = $db->query("
SELECT t.tid, t.firstpost
FROM ".TABLE_PREFIX."threads t

		$query = $db->query("
SELECT t.tid, t.firstpost
FROM ".TABLE_PREFIX."threads t

			WHERE 1=1 $thread_datecut $forumin $thread_usersql $permsql AND t.visible>0 $subject_lookin

			WHERE 1=1 $thread_datecut $thread_replycut $forumin $thread_usersql $permsql AND t.visible>0 $subject_lookin

		");
while($thread = $db->fetch_array($query))
{

		");
while($thread = $db->fetch_array($query))
{

Zeile 541Zeile 554
				$posts[$post['pid']] = $post['pid'];
}
$posts = implode(",", $posts);

				$posts[$post['pid']] = $post['pid'];
}
$posts = implode(",", $posts);

		}
}

		}
}

	return array(
"searchtype" => $searchtype,
"threads" => $threads,

	return array(
"searchtype" => $searchtype,
"threads" => $threads,

Zeile 601Zeile 614
						$lang->error_minsearchlength = sprintf($lang->error_minsearchlength, $mybb->settings['minsearchword']);
error($lang->error_minsearchlength);
}

						$lang->error_minsearchlength = sprintf($lang->error_minsearchlength, $mybb->settings['minsearchword']);
error($lang->error_minsearchlength);
}

				}

				}

			}
else
{

			}
else
{

Zeile 661Zeile 674
		$datecut .= "'$datelimit'";
$post_datecut = " AND p.dateline $datecut";
$thread_datecut = " AND t.dateline $datecut";

		$datecut .= "'$datelimit'";
$post_datecut = " AND p.dateline $datecut";
$thread_datecut = " AND t.dateline $datecut";

 
	}

$thread_replycut = "";
if($search['numreplies'] != "" && $search['findthreadst'])
{
if(intval($search['findthreadst']) == 1)
{
$thread_replycut = " AND t.replies >= '".intval($search['numreplies'])."'";
}
else
{
$thread_replycut = " AND t.replies <= '".intval($search['numreplies'])."'";
}

	}

$forumin = "";

	}

$forumin = "";

Zeile 717Zeile 743
		$query = $db->query("
SELECT t.tid, t.firstpost
FROM ".TABLE_PREFIX."threads t

		$query = $db->query("
SELECT t.tid, t.firstpost
FROM ".TABLE_PREFIX."threads t

			WHERE 1=1 $thread_datecut $forumin $thread_usersql $permsql AND t.visible>0 AND t.closed NOT LIKE 'moved|%' $subject_lookin

			WHERE 1=1 $thread_datecut $thread_replycut $forumin $thread_usersql $permsql AND t.visible>0 AND t.closed NOT LIKE 'moved|%' $subject_lookin

		");
while($thread = $db->fetch_array($query))
{

		");
while($thread = $db->fetch_array($query))
{

Zeile 731Zeile 757
			SELECT p.pid, p.tid
FROM ".TABLE_PREFIX."posts p
LEFT JOIN ".TABLE_PREFIX."threads t ON (t.tid=p.tid)

			SELECT p.pid, p.tid
FROM ".TABLE_PREFIX."posts p
LEFT JOIN ".TABLE_PREFIX."threads t ON (t.tid=p.tid)

			WHERE 1=1 $post_datecut $forumin $post_usersql $permsql AND p.visible>0 AND t.visible>0 AND t.closed NOT LIKE 'moved|%' $message_lookin

			WHERE 1=1 $post_datecut $thread_replycut $forumin $post_usersql $permsql AND p.visible>0 AND t.visible>0 AND t.closed NOT LIKE 'moved|%' $message_lookin

		");
while($post = $db->fetch_array($query))
{

		");
while($post = $db->fetch_array($query))
{

Zeile 753Zeile 779
		$query = $db->query("
SELECT t.tid, t.firstpost
FROM ".TABLE_PREFIX."threads t

		$query = $db->query("
SELECT t.tid, t.firstpost
FROM ".TABLE_PREFIX."threads t

			WHERE 1=1 $thread_datecut $forumin $thread_usersql $permsql AND t.visible>0 $subject_lookin

			WHERE 1=1 $thread_datecut $thread_replycut $forumin $thread_usersql $permsql AND t.visible>0 $subject_lookin

		");
while($thread = $db->fetch_array($query))
{

		");
while($thread = $db->fetch_array($query))
{