hej,
zribilem male co noeco, ale mam problem:
mimo ze przepisalem kod jezyczny, przy winnikach wypisuje mi zamiast séowa obraz (obrazy) wypisuje artykulim :((
To jest kod:
require_once "maincore.php";
include LOCALE.LOCALESET."photosearch.php";
$meta_title = " : ".$locale['400'];
require_once "subheader.php";
require_once "side_left.php";
if (!isset($rowstart) || !isNum($rowstart)) $rowstart = 0;
if (isset($stype)) $stype = $stype;
if (isset($stext)) $stext = stripinput($stext);
if (!isset($stype)) $stype = isset($_POST['stype']) ? $_POST['stype'] : "a";
if (!isset($stext)) $stext = isset($_POST['stext']) ? $_POST['stext'] : "";
opentable($locale['400']);
echo "<center>
<form name='searchform' method='post' action='".FUSION_SELF."'>
".$locale['401']." <input type='text' name='stext' value='$stext' class='textbox' style='width:200px'>
<input type='submit' name='search' value='".$locale['408']."' class='button'><br>
<input type='radio' name='stype' value='a'".($stype == "a" ? " checked" : "")."> fotografie
<input type='radio' name='stype' value='d'".($stype == "d" ? " checked" : "")."> ".$locale['405']."
<input type='radio' name='stype' value='w'".($stype == "w" ? " checked" : "")."> ".$locale['406']."
<input type='radio' name='stype' value='m'".($stype == "m" ? " checked" : "")."> ".$locale['407']."
</form>
</center>
<hr>\n";
closetable();
if ($stext != "" && strlen($stext > "3")) {
opentable($locale['409']);
if ($stype == "a") {
$result = dbquery( "SELECT ta.* FROM ".$db_prefix."photos ta
WHERE (photo_title LIKE '%$stext%')"
);
$rows = dbrows($result);
if ($rows != 0) {
echo $rows." ".($rows == 1 ? $locale['410'] : $locale['411']).$locale['422'].":<br><br>\n";
$result = dbquery(
"SELECT ta.* FROM ".$db_prefix."photos ta
WHERE (photo_title LIKE '%$stext%')
ORDER BY photo_date DESC LIMIT $rowstart,10"
);
while ($data = dbarray($result)) {
if (eregi($stext, $data['photo_title']) && eregi($stext, $data['photo_title'])) {
$subj_c = substr_count(strtolower($data['photo_title']), strtolower($stext));
$text_c = substr_count(strtolower($data['photo_title']), strtolower($stext));
echo "<a href='photogallery.php?photo=".$data['photo_id']."'>".$data['photo_title']."</a><br>\n";
// echo "<span class='small2'>".$locale['040']."<a href='profile.php?lookup=".$data['user_id']."'>".$data['user_name']."</a>\n";
// echo $locale['041'].showdate("longdate", $data['photo_date'])."</span><br>\n";
// echo "<span class='small'>".$subj_c." ".($subj_c == 1 ? "Match" : "Matches").$locale['432'].$locale['433'].", ";
// echo $text_c." ".($text_c == 1 ? "Match" : "Matches").$locale['432'].$locale['434']."</span><br><br>";
} elseif (eregi($stext, $data['photo_title'])) {
$text_c = substr_count(strtolower($data['photo_title']), strtolower($stext));
echo "<a href='photogallery.php?photo=".$data['photo_id']."'>".$data['photo_title']."</a><br>\n";
// echo "<span class='small2'>".$locale['040']."<a href='profile.php?lookup=".$data['user_id']."'>".$data['user_name']."</a>\n";
// echo $locale['041'].showdate("longdate", $data['photo_date'])."</span><br>\n";
// echo "<span class='small'>".$text_c." ".($text_c == 1 ? "Match" : "Matches").$locale['432'].$locale['434']."</span><br><br>";
} elseif (eregi($stext, $data['photo_title'])) {
$subj_c = substr_count(strtolower($data['photo_title']), strtolower($stext));
echo "<a href='photogallery.php?photo=".$data['photo_id']."'>".$data['photo_title']."</a><br>\n";
// echo "<span class='small2'>".$locale['040']."<a href='profile.php?lookup=".$data['user_id']."'>".$data['user_name']."</a>\n";
// echo $locale['041'].showdate("longdate", $data['photo_date'])."</span><br>\n";
// echo "<span class='small'>".$subj_c." ".($subj_c == 1 ? "Match" : "Matches").$locale['432'].$locale['433']."</span><br>";
}
}
} else {
echo "<center>0 ".$locale['411'].$locale['422'].".</center>\n";
}
closetable();
co tu nie jest tak ?
|