Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Šiandien užeinu i saita o jis susikraipes gal zinot kas cia negerai? url http://redorchestra.lt
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Susikuriu .htaccess failiuka i ji irasau
AuthName "Section Name"
AuthType Basic
AuthUserFile /administrator/.htpasswd
Require valid-user
P to susikuriu .htpasswd
susigeneruoju koda iklijuoju uzsaugau ir sumetu i ftp. Noriu eiti i adminke praso nick pass suvedu ir ismeta error The page you are looking for is temporarily unavailable.
Please try again later.
.
Gal kas zino del ko?
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Sveiki. Prireikė jūsų pagalbos. Sugalvojau į naujienas įdiegti seo, susiradau pamoką viska padariau kaip rašė ir ant galo rašo, kad reikia theme.php faile šita kodą
echo openform("N",$info['news_id']).newsopts($info,"·").closeform("N",$info['news_id']);
pakeisti šitu
echo openform("N",$info['news_id']).newsposter($info," ·")
.seonewsopts($info,"·").closeform("N",$info['news_id']);
Viskas būtų be problemų tačiau aš savo theme.php faile naujienas esu persidaręs
<td align='right' class='news-footer' ><a href='news.php?readmore=". $info ['news_id']."' class='ni' style='padding-right: 20px;'><u>Skaityti daugiau</u></a>
<a href='news.php?readmore=".$info['news_id']."' class='ni' style='padding-right: 20px;'><u>Komentarai:[".$info['news_comments']."]</u></a>\n";
echo "</td>
</tr>
</table>\n";
}
Taigi klausimas būtų toks ar eitų į mano koda kaip nors įkišti ta antrą kodą, kad veiktų seo?
http://Online-Tv.LT
Koduoju Php-Fusion dizainus
Redagavo Zeck 2010 Bir. 5 14:06:09 |
.Vaidas.
Narys
Kapitonas
Pranešimai: 707
Įstojęs: 2010 Kov. 11 19:03:37
|
Kodėl niekas jam nepadeda, aš čia beveik nieko neįkertu. D
Earth's Special Forces bendruomenė - ESForces.lt
[center][ce |
Impossibru
Narys
Ekspertas
Pranešimai: 3157
Įstojęs: 2007 Spa. 12 14:10:08
|
Kokį tu čia SEO naudoji?
Andrejaus tinklalapis |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Kaip suprast koki? Naujienu, su seoname ir .htaccess
http://www.phpfusion-mods.net/ar...ticle_id=3
http://Online-Tv.LT
Koduoju Php-Fusion dizainus
Redagavo Zeck 2010 Bir. 5 15:06:11 |
Impossibru
Narys
Ekspertas
Pranešimai: 3157
Įstojęs: 2007 Spa. 12 14:10:08
|
Matos kaip skaitai gerai, 5 komentaras po tuo straipsniu:
News:
Find:
$news_subject = "<a name='news_".$data['news_id']."' id='news_".$data['news_id']."'></a>".stripslashes($data['news_subject']);
Add below:
// Seo mod begin
$seoSubject = stripslashes($data['news_subject']);
// Seo mod end
Find:
$news_cat_image = "<a href='news_cats.php?cat_id=".$data['news_cat_id']."'><img src='".IMAGES_NC.$data['news_cat_image']."' alt='".$data['news_cat_name']."' align='left' style='border:0px;margin-top:3px;margin-right:5px'></a>";
Replace with:
$news_cat_image = "<a href='".seoname($data['news_cat_name'])."-nc".$data['news_cat_id'].".htm'><img src='".IMAGES_NC.$data['news_cat_image']."' alt='".$data['news_cat_name']."' align='left' style='border:0px;margin-top:3px;margin-right:5px'></a>";
Find:
$news_[0] .= $news_info['news_ext'] == "y" ? "<a href='".FUSION_SELF."?readmore=".$news_info['news_id']."'>".$locale['042']."</a> ·\n" : "";
Replace with:
$news_[0] .= $news_info['news_ext'] == "y" ? "<a href='".seoname($seoSubject)."-rn".$news_info['news_id'].".htm'>".$locale['042']."</a> ·\n" : "";
Find:
$news_[0] .= $news_info['news_allow_comments'] ? "<a href='".FUSION_SELF."?readmore=".$news_info['news_id']."'>".$news_info['news_comments'].$locale['043']."</a> ·\n" : "";
Replace with:
$news_[0] .= $news_info['news_allow_comments'] ? "<a href='".seoname($seoSubject)."-rn".$news_info['news_id'].".htm'>".$news_info['news_comments'].$locale['043']."</a> ·\n" : "";
Find:
$news_[$ncolumn] .= $news_info['news_ext'] == "y" ? "<a href='".FUSION_SELF."?readmore=".$news_info['news_id']."'>".$locale['042']."</a> ·\n" : "";
Replace with:
$news_[$ncolumn] .= $news_info['news_ext'] == "y" ? "<a href='".seoname($seoSubject)."-rn".$news_info['news_id'].".htm'>".$locale['042']."</a> ·\n" : "";
Find:
$news_[$ncolumn] .= $news_info['news_allow_comments'] ? "<a href='".FUSION_SELF."?readmore=".$news_info['news_id']."'>".$news_info['news_comments'].$locale['043']."</a> ·\n" : "";
Replace with:
$news_[$ncolumn] .= $news_info['news_allow_comments'] ? "<a href='".seoname($seoSubject)."-rn".$news_info['news_id'].".htm'>".$news_info['news_comments'].$locale['043']."</a> ·\n" : "";
Find:
$ncount++;
} else {
Add below:
$news_info['news_subject'] = $seoSubject;
Find:
$news_cat_image = "<a href='news_cats.php?cat_id=".$data2['news_cat_id']."'><img src='".IMAGES_NC.$data2['news_cat_image']."' alt='".$data2['news_cat_name']."' align='left' style='border:0px;margin-top:3px;margin-right:5px'></a>";
Replace with:
$news_cat_image = "<a href='".seoname($data2['news_cat_name'])."-nc".$data2['news_cat_id'].".htm'><img src='".IMAGES_NC.$data2['news_cat_image']."' alt='".$data2['news_cat_name']."' align='left' style='border:0px;margin-top:3px;margin-right:5px'></a>";
Done!
Andrejaus tinklalapis |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
news.php buvo pridetas maciau sita pagalvojau kad cia tiem kurie kazka yra dare su savo news.php ir kad patys pasiredaguotu
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Pasidariau tokia nuoroda <a href='".seoname($data['news_subject'])."-rn".$data['news_id'].".htm'>
Bet kai spaudziu skaityti daugiau tinklapis persikrauna ir viskas, neparodo visos naujienos. Gal galit kas patvarkyt sita nuoroda
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
edeni
Narys
Terminatorius
Pranešimai: 1502
Įstojęs: 2008 Vas. 7 19:02:18
|
<a href='".seoname($subject)."-rn".$info['news_id'].".html>
http://itouch.lt - iBendruomenė. |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Goku viskas butu klase bet nuoroda nekokia gaunas
%3Ca-name-news-18-id-news-18-%3E%3C-a%3EPati-naujausia-naujiena-rn1.html
Gal dar galetum pakoreguoti koda kad sita eilute dingtu?%3Ca-name-news-18-id-news-18-%3E%3C-a%3E
EDIT: paspaudiau perziureti kitas naujienas ir is viso pradejo nebeveikti :| nuoroda meta ta pacia bet klaida ismeta ?:|
http://Online-Tv.LT
Koduoju Php-Fusion dizainus
Redagavo Zeck 2010 Bir. 6 19:06:51 |
edeni
Narys
Terminatorius
Pranešimai: 1502
Įstojęs: 2008 Vas. 7 19:02:18
|
<?
function seoname($seoit) {
$seoit = strip_tags($seoit);
$seoit = str_replace('=',' ',$seoit);
$seoit = str_replace('/',' ',$seoit);
$seoit = str_replace('\\',' ',$seoit);
$seoit = str_replace('@',' ',$seoit);
$seoit = str_replace('~',' ',$seoit);
$seoit = str_replace('!',' ',$seoit);
$seoit = str_replace('£',' ',$seoit);
$seoit = str_replace('?',' ',$seoit);
$seoit = str_replace('!',' ',$seoit);
$seoit = str_replace('$',' ',$seoit);
$seoit = str_replace('%',' ',$seoit);
$seoit = str_replace('^',' ',$seoit);
$seoit = str_replace('*',' ',$seoit);
$seoit = str_replace('_',' ',$seoit);
$seoit = str_replace('{',' ',$seoit);
$seoit = str_replace('}',' ',$seoit);
$seoit = str_replace('[',' ',$seoit);
$seoit = str_replace(']',' ',$seoit);
$seoit = str_replace('-',' ',$seoit);
$seoit = str_replace(' & ',' ',$seoit);
$seoit = str_replace('"',' ',$seoit);
$seoit = str_replace('.',' ',$seoit);
$seoit = str_replace('\'',' ',$seoit);
$seoit = str_replace(',',' ',$seoit);
$seoit = str_replace(' ','-',$seoit);
$seoit = str_replace(' ','-',$seoit);
$seoit = str_replace(' ','-',$seoit);
$seoit = str_replace(':','',$seoit);
$seoit = str_replace('#','',$seoit);
$seoit = str_replace('(','',$seoit);
$seoit = str_replace(')','',$seoit);
$seoit = str_replace('---','-',$seoit);
$seoit = str_replace('--','-',$seoit);
$seoit = strtolower($seoit);
return $seoit;
}
function seonewsopts($info,$sep,$class="") {
global $locale; $res = "";
$link_class = $class ? " class='$class' " : "";
if (!isset($_GET['readmore']) && $info['news_ext'] == "y") $res = "<a href='".seoname($info['news_subject'])."-rn".$info['news_id'].".htm'".$link_class.">".$locale['042']."</a> ".$sep." ";
if ($info['news_allow_comments']) $res .= "<a href='".seoname($info['news_subject'])."-rn".$info['news_id'].".htm'".$link_class.">".$info['news_comments'].$locale['043']."</a> ".$sep." ";
if ($info['news_ext'] == "y" || $info['news_allow_comments']) $res .= $info['news_reads'].$locale['044']."\n";
$res .= $sep." <a href='print.php?type=N&item_id=".$info['news_id']."'><img src='".THEME."images/printer.gif' alt='".$locale['045']."' style='vertical-align:middle;border:0px;'></a>\n";
return $res;
}
?>
įdėk šita seoname.php failą ir nesakyk, kad neveikia pats esu taip pasidaręs ir kuo puikiausiai veikia. Jeigu neveikia reiškia rankos kreivos.
http://itouch.lt - iBendruomenė.
Redagavo edeni 2010 Bir. 6 19:06:38 |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Dabar nuoroda tobula, taciau neatidaro puslapio, not found meta. O pries tai viska puikiai atidare, nesuprantu kas cia pasidare
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
edeni
Narys
Terminatorius
Pranešimai: 1502
Įstojęs: 2008 Vas. 7 19:02:18
|
Tai čia jau pas tave problemos, nes pas mane kuo puikiausiai veikia.
Atsidaryk .htaccess ir ten įrašyk
RewriteRule ^(.*)-rn([0-9]*).html$ news.php?readmore=$2 [L,NC]
http://itouch.lt - iBendruomenė.
Redagavo edeni 2010 Bir. 6 19:06:20 |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Gal news.php neatitinka?
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
Impossibru
Narys
Ekspertas
Pranešimai: 3157
Įstojęs: 2007 Spa. 12 14:10:08
|
".seoname($info['news_subject'])."-rn".$info['news_id'].".htm
Žiūrėkis .htaccess failą kaip yra parašyta jau...
Andrejaus tinklalapis |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Abiem po +10 pas Goku buvo galune html Del to nieko ir nesigavo. Dekui abiem
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Gal kas žino iš kur gauti toki arba panašų balsavimo scripta?
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
edeni
Narys
Terminatorius
Pranešimai: 1502
Įstojęs: 2008 Vas. 7 19:02:18
|
Ant V7 http://www.ltfusion.lt/siuntinys,35
http://itouch.lt - iBendruomenė. |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
O ant v6 nera?
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
DEMO_user
Narys
Buldozeris
Pranešimai: 207
Įstojęs: 2010 Kov. 23 12:03:52
|
Yra, mačiau ant kelių svetainių, bet ainu dar paieškoti internete, gal raiu įmesiu.
|
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Butu neblogai pats ieskojau bet v6 neradau
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Gal kas galetu is search.php istrinti visus pasirinkimus ko ieskoti ir palikti jog ieskotu tik naujienu? :)
Stai kodas
<?php
/*---------------------------------------------------+
| PHP-Fusion 6 Content Management System
+----------------------------------------------------+
| Copyright © 2002 - 2006 Nick Jones
| http://www.php-fusion.co.uk/
+----------------------------------------------------+
| Released under the terms & conditions of v2 of the
| GNU General Public License. For details refer to
| the included gpl.txt file or visit http://gnu.org
+----------------------------------------------------*/
require_once "maincore.php";
require_once "subheader.php";
require_once "side_left.php";
include LOCALE.LOCALESET."search.php";
$news_per_page = 11; $posts_per_page = 20;
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']) ? stripinput($_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" : "")."> ".$locale['402']."
<input type='radio' name='stype' value='n'".($stype == "n" ? " checked" : "")."> ".$locale['403']."
<input type='radio' name='stype' value='f'".($stype == "f" ? " checked" : "")."> ".$locale['404']."
<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>\n";
closetable();
if ($stext != "" && strlen($stext) >= "3") {
tablebreak();
opentable($locale['409']);
if ($stype == "a") {
$result = dbquery(
"SELECT ta.*,tac.* FROM ".$db_prefix."articles ta
INNER JOIN ".$db_prefix."article_cats tac ON ta.article_cat=tac.article_cat_id
WHERE ".groupaccess('article_cat_access')." AND (article_subject LIKE '%$stext%' || article_article 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.*,tac.*, tu.user_id,user_name FROM ".$db_prefix."articles ta
INNER JOIN ".$db_prefix."article_cats tac ON ta.article_cat=tac.article_cat_id
LEFT JOIN ".$db_prefix."users tu ON ta.article_name=tu.user_id
WHERE ".groupaccess('article_cat_access')." AND (article_subject LIKE '%$stext%' || article_article LIKE '%$stext%')
ORDER BY article_datestamp DESC LIMIT $rowstart,10"
);
while ($data = dbarray($result)) {
if (eregi($stext, $data['article_subject']) && eregi($stext, $data['article_article'])) {
$subj_c = substr_count(strtolower($data['article_subject']), strtolower($stext));
$text_c = substr_count(strtolower($data['article_article']), strtolower($stext));
echo "<a href='readarticle.php?article_id=".$data['article_id']."'>".$data['article_subject']."</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['article_datestamp'])."</span><br>\n";
echo "<span class='small'>".$subj_c." ".($subj_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['433'].", ";
echo $text_c." ".($text_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['434']."</span><br><br>";
} elseif (eregi($stext, $data['article_article'])) {
$text_c = substr_count(strtolower($data['article_article']), strtolower($stext));
echo "<a href='readarticle.php?article_id=".$data['article_id']."'>".$data['article_subject']."</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['article_datestamp'])."</span><br>\n";
echo "<span class='small'>".$text_c." ".($text_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['434']."</span><br><br>";
} elseif (eregi($stext, $data['article_subject'])) {
$subj_c = substr_count(strtolower($data['article_subject']), strtolower($stext));
echo "<a href='readarticle.php?article_id=".$data['article_id']."'>".$data['article_subject']."</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['article_datestamp'])."</span><br>\n";
echo "<span class='small'>".$subj_c." ".($subj_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['433']."</span><br>";
}
}
} else {
echo "<center>0 ".$locale['411'].$locale['422'].".</center>\n";
}
closetable();
if ($rows > 10) echo "<div align='center' style='margin-top:5px;'>\n".makePageNav($rowstart,10,$rows,3,FUSION_SELF."?stype=a&stext=$stext&")."\n</div>\n";
} else if ($stype == "n") {
$rows = dbcount("(news_id)", "news", groupaccess('news_visibility')."AND (news_subject LIKE '%$stext%' || news_news LIKE '%$stext%' || news_extended LIKE '%$stext%')");
if ($rows != 0) {
echo $rows." ".($rows == 1 ? $locale['412'] : $locale['413']).$locale['422'].":<br><br>\n";
$result = dbquery(
"SELECT tn.*, user_id, user_name FROM ".$db_prefix."news tn
LEFT JOIN ".$db_prefix."users tu ON tn.news_name=tu.user_id
WHERE ".groupaccess('news_visibility')." AND (news_start='0'||news_start<=".time().")
AND (news_end='0'||news_end>=".time().") AND (news_subject LIKE '%$stext%' || news_news LIKE '%$stext%' || news_extended LIKE '%$stext%')
ORDER BY news_datestamp DESC LIMIT $rowstart,10"
);
while ($data = dbarray($result)) {
$numrows = dbcount("(news_id)", "news", groupaccess('news_visibility')." AND news_id>='".$data['news_id']."'");
if ($numrows > $news_per_page) {
$rstart = ceil($numrows / $news_per_page);
$rstart = "?rowstart=".(($rstart-1)*$news_per_page);
} else {
$rstart = "";
}
if (eregi($stext, $data['news_subject']) && eregi($stext, $data['news_news']) && eregi($stext, $data['news_extended'])) {
$subj_c = substr_count(strtolower($data['news_subject']), strtolower($stext));
$text_c = substr_count(strtolower($data['news_news']), strtolower($stext));
$text_c2 = substr_count(strtolower($data['news_extended']), strtolower($stext));
echo "<a href='news.php".$rstart."#news_".$data['news_id']."'>".$data['news_subject']."</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['news_datestamp'])."</span><br>\n";
echo "<span class='small'>".$subj_c." ".($subj_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['435'].", ";
echo $text_c." ".($text_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['436'].", ";
echo $text_c2." ".($text_c2 == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['437']."</span><br><br>";
} elseif (eregi($stext, $data['news_subject']) && eregi($stext, $data['news_news'])) {
$subj_c = substr_count(strtolower($data['news_subject']), strtolower($stext));
$text_c = substr_count(strtolower($data['news_news']), strtolower($stext));
echo "<a href='news.php".$rstart."#news_".$data['news_id']."'>".$data['news_subject']."</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['news_datestamp'])."</span><br>\n";
echo "<span class='small'>".$subj_c." ".($subj_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['435'].", ";
echo $text_c." ".($text_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['436']."</span><br><br>";
} elseif (eregi($stext, $data['news_subject']) && eregi($stext, $data['news_extended'])) {
$subj_c = substr_count(strtolower($data['news_subject']), strtolower($stext));
$text_c = substr_count(strtolower($data['news_extended']), strtolower($stext));
echo "<a href='news.php?readmore=".$data['news_id']."'>".$data['news_subject']."</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['news_datestamp'])."</span><br>\n";
echo "<span class='small'>".$subj_c." ".($subj_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['435'].", ";
echo $text_c." ".($text_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['437']."</span><br><br>";
} elseif (eregi($stext, $data['news_news']) && eregi($stext, $data['news_extended'])) {
$text_c = substr_count(strtolower($data['news_news']), strtolower($stext));
$text_c2 = substr_count(strtolower($data['news_extended']), strtolower($stext));
echo "<a href='news.php".$rstart."#news_".$data['news_id']."'>".$data['news_subject']."</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['news_datestamp'])."</span><br>\n";
echo "<span class='small'>".$text_c." ".($text_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['436'].", ";
echo $text_c2." ".($text_c2 == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['437']."</span><br><br>";
} elseif (eregi($stext, $data['news_news'])) {
$text_c = substr_count(strtolower($data['news_news']), strtolower($stext));
echo "<a href='news.php".$rstart."#news_".$data['news_id']."'>".$data['news_subject']."</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['news_datestamp'])."</span><br>\n";
echo "<span class='small'>".$text_c." ".($text_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['436']."</span><br><br>";
} elseif (eregi($stext, $data['news_extended'])) {
$text_c = substr_count(strtolower($data['news_extended']), strtolower($stext));
echo "<a href='news.php?readmore=".$data['news_id']."'>".$data['news_subject']."</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['news_datestamp'])."</span><br>\n";
echo "<span class='small'>".$text_c." ".($text_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['437']."</span><br><br>";
} elseif (eregi($stext, $data['news_subject'])) {
$subj_c = substr_count(strtolower($data['news_subject']), strtolower($stext));
echo "<a href='news.php".$rstart."#news_".$data['news_id']."'>".$data['news_subject']."</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['news_datestamp'])."</span><br>\n";
echo "<span class='small'>".$subj_c." ".($subj_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['437']."</span><br><br>";
}
}
} else {
echo "<center>0 ".$locale['413'].$locale['422'].".</center>\n";
}
closetable();
if ($rows > 10) echo "<div align='center' style='margin-top:5px;'>\n".makePageNav($rowstart,10,$rows,3,FUSION_SELF."?stype=n&stext=$stext&")."\n</div>\n";
} elseif ($stype == "f") {
$result = dbquery(
"SELECT tp.*, tf.* FROM ".$db_prefix."posts tp
INNER JOIN ".$db_prefix."forums tf USING(forum_id)
WHERE ".groupaccess('forum_access')." AND (post_subject LIKE '%$stext%' || post_message LIKE '%$stext%')"
);
$rows = dbrows($result);
if ($rows != 0) {
echo $rows." ".($rows == 1 ? $locale['414'] : $locale['415']).$locale['422'].":<br><br>\n";
$result = dbquery(
"SELECT tp.*, tf.*, tu.user_id,user_name FROM ".$db_prefix."posts tp
INNER JOIN ".$db_prefix."forums tf USING(forum_id)
INNER JOIN ".$db_prefix."users tu ON tp.post_author=tu.user_id
WHERE ".groupaccess('forum_access')." AND (post_subject LIKE '%$stext%' || post_message LIKE '%$stext%')
ORDER BY post_datestamp DESC LIMIT $rowstart,10"
);
while ($data = dbarray($result)) {
if (eregi($stext, $data['post_subject']) && eregi($stext, $data['post_message'])) {
$subj_c = substr_count(strtolower($data['post_subject']), strtolower($stext));
$text_c = substr_count(strtolower($data['post_message']), strtolower($stext));
echo "<a href='".FORUM."viewthread.php?forum_id=".$data['forum_id']."&thread_id=".$data['thread_id']."&pid=".$data['post_id']."#post_".$data['post_id']."'>".$data['post_subject']."</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['post_datestamp'])."</span><br>\n";
echo "<span class='small'>".$subj_c." ".($subj_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['438'].", ";
echo $text_c." ".($text_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['439']."</span><br><br>";
} elseif (eregi($stext, $data['post_message'])) {
$text_c = substr_count(strtolower($data['post_message']), strtolower($stext));
echo "<a href='".FORUM."viewthread.php?forum_id=".$data['forum_id']."&thread_id=".$data['thread_id']."&pid=".$data['post_id']."#post_".$data['post_id']."'>".$data['post_subject']."</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['post_datestamp'])."</span><br>\n";
echo "<span class='small'>".$text_c." ".($text_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['439']."</span><br><br>";
} elseif (eregi($stext, $data['post_subject'])) {
$subj_c = substr_count(strtolower($data['post_subject']), strtolower($stext));
echo "<a href='".FORUM."viewthread.php?forum_id=".$data['forum_id']."&thread_id=".$data['thread_id']."&pid=".$data['post_id']."#post_".$data['post_id']."'>".$data['post_subject']."</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['post_datestamp'])."</span><br>\n";
echo "<span class='small'>".$subj_c." ".($subj_c == 1 ? $locale['430'] : $locale['431']).$locale['432'].$locale['438']."</span><br><br>";
}
}
} else {
echo "<center>0 ".$locale['415'].$locale['422'].".</center>\n";
}
closetable();
if ($rows > 10) echo "<div align='center' style='margin-top:5px;'>\n".makePageNav($rowstart,10,$rows,3,FUSION_SELF."?stype=f&stext=$stext&")."\n</div>\n";
} elseif ($stype == "d") {
$result = dbquery(
"SELECT td.*,tdc.* FROM ".$db_prefix."downloads td
INNER JOIN ".$db_prefix."download_cats tdc ON td.download_cat=tdc.download_cat_id
WHERE ".groupaccess('download_cat_access')." AND (download_title LIKE '%$stext%' || download_description LIKE '%$stext%')"
);
$rows = dbrows($result);
if ($rows != 0) {
echo $rows." ".($rows == 1 ? $locale['416'] : $locale['417']).$locale['422'].":<br><br>\n";
$result = dbquery(
"SELECT td.*,tdc.* FROM ".$db_prefix."downloads td
INNER JOIN ".$db_prefix."download_cats tdc ON td.download_cat=tdc.download_cat_id
WHERE ".groupaccess('download_cat_access')." AND (download_title LIKE '%$stext%' || download_description LIKE '%$stext%')
ORDER BY download_title LIMIT $rowstart,10"
);
$i = 1;
while ($data = dbarray($result)) {
if ($data['download_datestamp']+604800 > time()+($settings['timeoffset']*3600)) {
$new = " <span class='small'>".$locale['450']."</span>";
} else {
$new = "";
}
echo "<a href='downloads.php?cat_id=".$data['download_cat']."&download_id=".$data['download_id']."' target='_blank'>".$data['download_title']."</a> - ".$data['download_filesize']." $new<br>\n";
if ($data['download_description'] != "") echo stripslashes($data['download_description'])."<br>\n";
echo "<span class='small'><font class='alt'>".$locale['451']."</font> ".$data['download_license']." |
<font class='alt'>".$locale['452']."</font> ".$data['download_os']." |
<font class='alt'>".$locale['453']."</font> ".$data['download_version']."<br>
<font class='alt'>".$locale['454']."</font> ".showdate("%d.%m.%y", $data['download_datestamp'])." |
<font class='alt'>".$locale['455']."</font> ".$data['download_count']."</span>\n";
if ($i != $numrows) { echo "<br><br>\n"; } else { echo "\n"; }
$i++;
}
} else {
echo "<center>0 ".$locale['417'].$locale['422'].".</center>\n";
}
closetable();
if ($rows > 10) echo "<div align='center' style='margin-top:5px;'>\n".makePageNav($rowstart,10,$rows,3,FUSION_SELF."?stype=d&stext=$stext&")."\n</div>\n";
} elseif ($stype == "w") {
$result = dbquery(
"SELECT tw.*,twc.* FROM ".$db_prefix."weblinks tw
INNER JOIN ".$db_prefix."weblink_cats twc ON tw.weblink_cat=twc.weblink_cat_id
WHERE ".groupaccess('weblink_cat_access')." AND (weblink_name LIKE '%$stext%' || weblink_description LIKE '%$stext%')"
);
$rows = dbrows($result);
if ($rows != 0) {
echo $rows." ".($rows == 1 ? $locale['418'] : $locale['419']).$locale['422'].":<br><br>\n";
$result = dbquery(
"SELECT tw.*,twc.* FROM ".$db_prefix."weblinks tw
INNER JOIN ".$db_prefix."weblink_cats twc ON tw.weblink_cat=twc.weblink_cat_id
WHERE ".groupaccess('weblink_cat_access')." AND (weblink_name LIKE '%$stext%' || weblink_description LIKE '%$stext%')
ORDER BY weblink_name LIMIT $rowstart,10"
);
$i = 1;
while ($data = dbarray($result)) {
if ($data['weblink_datestamp']+604800 > time()+($settings['timeoffset']*3600)) {
$new = " <span class='small'>".$locale['450']."</span>";
} else {
$new = "";
}
echo "<a href='weblinks.php?cat_id=".$data['weblink_cat']."&weblink_id=".$data['weblink_id']."' target='_blank'>".$data['weblink_name']."</a>$new<br>\n";
if ($data['weblink_description'] != "") echo $data['weblink_description']."<br>\n";
echo "<span class='small'><font class='alt'>".$locale['454']."</font> ".showdate("%d.%m.%y", $data['weblink_datestamp'])." |
<span class='alt'>".$locale['456']."</span> ".$data['weblink_count']."</span>";
echo ($i != $numrows ? "<br><br>\n" : "\n"); $i++;
}
} else {
echo "<center>0 ".$locale['419'].$locale['422'].".</center>\n";
}
closetable();
if ($rows > 10) echo "<div align='center' style='margin-top:5px;'>\n".makePageNav($rowstart,10,$rows,3,FUSION_SELF."?stype=w&stext=$stext&")."\n</div>\n";
} elseif ($stype == "m") {
$rows = dbcount("(user_id)", "users", "user_name LIKE '%$stext%'");
if ($rows != 0) {
echo $rows." ".($rows == 1 ? $locale['420'] : $locale['421']).$locale['422'].":<br><br>\n";
$result = dbquery("SELECT * FROM ".$db_prefix."users WHERE user_name LIKE '%$stext%' ORDER BY user_name");
while ($data = dbarray($result)) {
echo "<a href='profile.php?lookup=".$data['user_id']."'>".$data['user_name']."</a><br>\n";
}
} else {
echo "<center>0 ".$locale['421'].$locale['422'].".</center>\n";
}
closetable();
}
}
require_once "side_right.php";
require_once "footer.php";
?>
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Sveiki. Gal zinote kaip padaryti kad naujienos pavadinime rodytu tik 30 raidziu, o jai pavadinimas ilgesnis toliau butu daugtaskiai?
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
MAnjack
Garbės narys
Legenda
Pranešimai: 11821
Įstojęs: 2006 Kov. 2 20:03:58
|
echo trimlink("pavadinimas", 30);
|
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Kur kisti sita koda? i theme ar i news.php ?
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Gal kas gali pasakyti kaip ikisti MAnjack koda ir news.php ? jog pavadinime rodytu tik 30 simboliu?
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
flapas
Narys
Generolas
Pranešimai: 908
Įstojęs: 2010 Geg. 31 20:05:14
|
Zeck parašė:
Gal kas gali pasakyti kaip ikisti MAnjack koda ir news.php ? jog pavadinime rodytu tik 30 simboliu?
parašyk į skype: namehas padėsiu.
[deleted url] |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Gal kas turi minciu kaip is sita koda iterpti simboliu limito koda, kad naujienos pavadinime rodyti tik 30 simboliu?
function render_news($subject, $news, $info) {
echo "<table cellpadding='0' cellspacing='0' width='557'
<tr>
<td class='capmain'>$subject</td>
</tr>
<tr>
<td class='main-body'>$news</td>
</tr>
<tr>
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
Impossibru
Narys
Ekspertas
Pranešimai: 3157
Įstojęs: 2007 Spa. 12 14:10:08
|
function render_news($subject, $news, $info) {
global $trimlink;
echo "<table cellpadding='0' cellspacing='0' width='557'
<tr>
<td class='capmain'>trimlink("$subject", 30);</td>
</tr>
<tr>
<td class='main-body'>$news</td>
</tr>
<tr>
}
Andrejaus tinklalapis
Redagavo Impossibru 2010 Bir. 23 15:06:40 |
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Parse error: syntax error, unexpected T_VARIABLE, expecting ',' or ';' in /home/zeck/domains/domenas/public_html/themes/tema/theme.php on line 68
http://Online-Tv.LT
Koduoju Php-Fusion dizainus
Redagavo Zeck 2010 Bir. 23 15:06:10 |
Pakartoti slaptažodį
Moderatorius
Viršesnis už Dievą
Pranešimai: 5188
Įstojęs: 2008 Rugp. 6 22:08:39
|
function render_news($subject, $news, $info) {
global $trimlink;
echo "<table cellpadding='0' cellspacing='0' width='557'
<tr>
<td class='capmain'>trimlink('$subject', 30);</td>
</tr>
<tr>
<td class='main-body'>$news</td>
</tr>
<tr>
}
|
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Follow dabar naujienos pavadinima taip rodo
trimlink('Naujienos pavadinimas', 30);
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
AgS
VIP narys
Margas
Pranešimai: 97
Įstojęs: 2010 Bir. 15 17:06:30
|
function render_news($subject, $news, $info) {
echo "<table cellpadding='0' cellspacing='0' width='557'
<tr>
<td class='capmain'>$subject</td>
</tr>
<tr>
<td class='main-body'>".trimlink($news,30)."</td>
</tr>
<tr>
|
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Man naujienos pavadinime reikia o ne pacioje naujienoje
http://Online-Tv.LT
Koduoju Php-Fusion dizainus
Redagavo Zeck 2010 Bir. 23 19:06:41 |
AgS
VIP narys
Margas
Pranešimai: 97
Įstojęs: 2010 Bir. 15 17:06:30
|
Tai tu news.php redaguok, prie to naujienos pavadinimo rašyk trimlink($subject,30);
tik $subject pasikeisk į tą, kuris naudojamas news.php
|
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Stai ta eilute
$news_subject = "<a name='news_".$data['news_id']."' id='news_".$data['news_id']."'></a>".stripslashes($data['news_subject']);
http://Online-Tv.LT
Koduoju Php-Fusion dizainus |
AgS
VIP narys
Margas
Pranešimai: 97
Įstojęs: 2010 Bir. 15 17:06:30
|
$news_subject = "<a name='news_".$data['news_id']."' id='news_".$data['news_id']."'></a>".stripslashes(trimlink($data['news_subject'],30));
štai
|
Zeck
Narys
Generolas
Pranešimai: 1074
Įstojęs: 2008 Lie. 4 18:07:58
|
Negerai. Parse error: syntax error, unexpected T_DNUMBER in /home/zeck/domains/domenas.lt/public_html/news.php on line 39
http://Online-Tv.LT
Koduoju Php-Fusion dizainus
Redagavo Zeck 2010 Bir. 23 19:06:38 |
AgS
VIP narys
Margas
Pranešimai: 97
Įstojęs: 2010 Bir. 15 17:06:30
|
redagavau po kelių sekundžių, buvau klaidą palikes
|