Gönderen Konu: haber kategoru ayirmak  (Okunma sayısı 864 defa)

0 Üye ve 1 Ziyaretçi konuyu incelemekte.

Çevrimdışı isabey

  • Moderatör
  • *
  • İleti: 585
  • Puan: 70
  • Cinsiyet: Bay
    • isabey koyu
haber kategoru ayirmak
« : Aralık 15, 2009, 12:07:46 ÖS »
sevgili dostlar orjinalini bozmadan kategoru ayirmak istiyorum kategoru haber 3 yapmak istiyorum nasil yapacagim saygilar

Kod: [Seç]
<?php
/*
+--------------------------------------------------------------------------
|   MkPortal
|   ========================================
|   by Meo aka Luponero <Amedeo de longis>
|      Don K. Colburn <visiblesoul.net>
|
|   Copyright (c) 2004-2006 mkportal.it
|   http://www.mkportal.it
|   Email: luponero@mclink.it
|
+---------------------------------------------------------------------------
|
|   > MKPortal
|   > Written By Amedeo de longis
|   > Date started: 9.2.2004
|
+--------------------------------------------------------------------------
|
|   > Dynamic Web News v1.0
|   > by Kimi - kimi@d3style.com <www.d3style.com>
|   > Based on a original idea by Onizuka88 - www.webinweb.net
|
+--------------------------------------------------------------------------
*/
if (!defined("IN_MKP")) {
    die (
"Sorry !! You cannot access this file directly.");
}

$limit $this->config['news_block'];
if (!
$limit) {
$limit 5;
}
$cont1 "";
$cont "";
$content "";
$link_user $mklib_board->forum_link("profile");



    
$query $DB->query"SELECT n.id, n.idcategoria, n.idautore, n.titolo, n.autore, n.testo, n.data, n.click, n.totalcomm, s.id AS idcat, s.titolo AS titcat, s.icona 
    FROM mkp_news AS n
    LEFT JOIN mkp_news_sections AS s ON(s.id = n.idcategoria)
    WHERE validate = '1' ORDER BY `id` DESC LIMIT $limit"
);
    while( 
$row $DB->fetch_row($query) ) {
        
$idnt $row['id'];
        
$totcomments $row['totalcomm'];
          
$click $row['click'];  
$id_orig_name $row['idautore'];
$idcategoria $row['idcategoria'];
$titolo stripslashes($row['titolo']);
$name $row['autore'];
$testo stripslashes($row['testo']);
if ($this->mkeditor == "BBCODE") {
$testo $this->decode_bb($testo);
$testo $mklib_board->decode_smilies($testo);
}
$sezione $row['titcat'];
$icona $row['icona'];
switch($icona) {
case '1':
$image "$this->images/icona_news.gif";
    
break;
case '2':
    
$image "$this->images/icona_help.gif";
    
break;
case '3':
$image "$this->images/icona_star.gif";
    
break;
case '4':
$image "$this->images/icona_pc.gif";
    
break;
case '5':
$image "$this->images/icona_world.gif";
    
break;
    
default:
    
$image $icona;
    
break;
    
}

$pinned $row['pinned'] ? "&nbsp;<img src=\"$this->images/pin.gif\" border=\"0\" alt=\"\" />" '';
$cdata $this->create_date($row['data']);
$news_words$this->config['news_words'];
if ($this->config['news_html']) {
$testo str_replace ("<br />"" "$testo);
$testo strip_tags ($testo);
   
}
if ($news_words) {
$testo substr ($testo0$news_words);
$testo .= " ...";
   
}
        
$cont1 .= "
<table class=\"tabnews\" cellspacing=\"2\" cellpadding=\"2\" width=\"100%\">
    <tbody>
    <tr>
      <td class=\"tdblock\" align=\"center\" width=\"5%\">
      <img hspace=\"0\" src=\"$image\" align=\"bottom\" border=\"0\" alt=\"\" />
      </td>
      <td class=\"tdblock\" valign=\"top\" width=\"95%\">
      <b>$sezione<br /><a href=\"#\" rel=\"$idnt\">$titolo</a></b>$pinned
      </td>
    </tr>
    </tbody>
  </table>
  "
;
$cont .= "
 <div id=\"$idnt\">
<table class=\"tabnews\" cellspacing=\"2\" cellpadding=\"2\" width=\"100%\">
    <tbody>
    <tr>
      <td>
  <b><a href=\"site/index.php?ind=news&amp;op=news_show_single&amp;ide={$row['id']}\">$titolo</a></b>
  <br />
      $testo
      </td>
    </tr>
    <tr>
      <td align=\"right\">
      <br /><i>{$this->lang['from']}<b> <a href=\"$link_user=$id_orig_name\">$name</a></b>, $cdata,Bu Haber: $click Defa Okundu,<a href=\"index.php?ind=news&amp;op=submit_comment&amp;idnews={$row['id']}\">{$this->lang['comments']}</a>($totcomments), <a href=\"index.php?ind=news&amp;op=news_show_single&amp;ide={$row['id']}\">{$this->lang['readall']}</a></i>) 
      </td>
    </tr>
    </tbody>
  </table>
</div>
"
;
}
$content "
<tr>
  <td class=\"contents\">
  <div class=\"taburlo\">
    <table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"2\">
      <tr>
<td width=\"50%\" id=\"countrytabs\" class=\"taburlo\" valign=\"top\">
{$cont1}
</td>
<td width=\"50%\" class=\"taburlo\" valign=\"top\">
{$cont}
</td>
      </tr>
    </table>
  </div>
  </td>
       </tr>


<script type=\"text/javascript\">

var countries=new ddtabcontent(\"countrytabs\")
countries.setpersist(true)
countries.setselectedClassTarget(\"link\") 
countries.init()

</script>

  "
;

unset($cont1);   
unset($cont);
unset($row);
unset($idcat);
unset($categoria);
unset($idnt);
unset($query);
unset($query2);
unset($totcomments);
unset($id_orig_name);
unset($idcategoria);
unset($titolo);
unset($name);
unset($testo);
unset($sezione);
unset($icona);
unset($cdata);
unset($news_words);
                unset(
$click);




?>

Konuyu Paylaş:
  delicious  facebook  twitter  google

Çevrimdışı isabey

  • Moderatör
  • *
  • İleti: 585
  • Puan: 70
  • Cinsiyet: Bay
    • isabey koyu
-haber kategoru ayirmak
« Yanıtla #1 : Aralık 16, 2009, 15:08:28 ÖS »
yardim ececek yokmu

Çevrimdışı AdmiN

  • Genel Sorumlu
  • Administrator
  • *
  • İleti: 7976
  • Puan: 750
  • Cinsiyet: Bay
  • ~|| Bilginin Gücü ||~
    • Kişisel Web Sitem
-haber kategoru ayirmak
« Yanıtla #2 : Aralık 16, 2009, 20:52:56 ÖS »
Tam anlamadım.İkili ya da dörtlü yanyana haber bloğu vardı.Onun gibi ama 3 blok halinde mi olsun istiyorsun?

Çevrimdışı isabey

  • Moderatör
  • *
  • İleti: 585
  • Puan: 70
  • Cinsiyet: Bay
    • isabey koyu
-haber kategoru ayirmak
« Yanıtla #3 : Aralık 17, 2009, 00:13:42 ÖÖ »
sitemde genel haber ,sporhaber, ilginc haber, koy haber, secme haberler var,
sadece secdigim haber o bolumde gostersindiyorum

bu sitede asagidaki bolok onu sadece spor haberleri icin yapmak istiyorum sadece spor kategoru
dynamic_web_news1

www.isabeykoyu.com/site

Çevrimdışı ZaFeRySb

  • Süper Moderatör
  • *
  • İleti: 389
  • Puan: 24
  • Cinsiyet: Bay
  • Ya olduğun gibi görün,ya da göründüğün gibi ol!
-haber kategoru ayirmak
« Yanıtla #4 : Aralık 17, 2009, 01:26:25 ÖÖ »
Dostum biraz baktım.Kodların içinde
Kod: [Seç]
  <b><a href=\"site/index.php?ind=news&amp;op=news_show_single&amp;ide={$row['id']}\">$titolo</a></b> kodu var.3 yerde.Blokta listelenen haberlerin sorgusu."id"kısmını listemek istediğin katagori id sini yazarsan düzelir galiba.Yedeğini al bi dene bakalım.

Çevrimdışı isabey

  • Moderatör
  • *
  • İleti: 585
  • Puan: 70
  • Cinsiyet: Bay
    • isabey koyu
-haber kategoru ayirmak
« Yanıtla #5 : Aralık 17, 2009, 11:27:11 ÖÖ »
hayir olmuyor kodlarin yukarisnda biryere exra kod eklenmsi grek sanirim malesef olmadi

Çevrimdışı isabey

  • Moderatör
  • *
  • İleti: 585
  • Puan: 70
  • Cinsiyet: Bay
    • isabey koyu
-haber kategoru ayirmak
« Yanıtla #6 : Aralık 17, 2009, 15:14:03 ÖS »
SORUNU COZDUM LINK ADRES KENDINEZE GORE AYARLAYIP KULANABILIRSINIZ


Kod: [Seç]
<?php
/*
+--------------------------------------------------------------------------
|   MkPortal
|   ========================================
|   by Meo aka Luponero <Amedeo de longis>
|      Don K. Colburn <visiblesoul.net>
|
|   Copyright (c) 2004-2006 mkportal.it
|   http://www.mkportal.it
|   Email: luponero@mclink.it
|
+---------------------------------------------------------------------------
|
|   > MKPortal
|   > Written By Amedeo de longis
|   > Date started: 9.2.2004
|
+--------------------------------------------------------------------------
|
|   > Dynamic Web News v1.0
|   > by Kimi - kimi@d3style.com <www.d3style.com>
|   > Based on a original idea by Onizuka88 - www.webinweb.net
|
+--------------------------------------------------------------------------
*/
if (!defined("IN_MKP")) {
    die (
"Sorry !! You cannot access this file directly.");
}
$cutoff 500//satirda kac karaktere kadar gorunsun
$limit $this->config['news_block'];
if (!
$limit) {
$limit 5;
}
$cont1 "";
$cont "";
$content "";
$link_user $mklib_board->forum_link("profile");



    
$query $DB->query"SELECT n.id, n.idcategoria, n.idautore, n.titolo, n.autore, n.testo, n.data, n.click, n.totalcomm, s.id AS idcat, s.titolo AS titcat, s.icona 
    FROM mkp_news AS n
LEFT JOIN mkp_news_sections AS s ON(s.id = n.idcategoria)
WHERE validate = '1' and idcategoria = '1' ORDER BY `id` DESC LIMIT 8"
);
while( $row $DB->fetch_row($query) ) {
$idnt $row['id'];
$totcomments $row['totalcomm'];
$id_orig_name $row['idautore'];
$idcategoria $row['idcategoria'];
$karaktersinir 100;
$titolo stripslashes($row['titolo']);
$titolo substr($titolo,0,$karaktersinir);
$name $row['autore'];
$testo stripslashes($row['testo']);
if ($this->mkeditor == "BBCODE") {
$testo $this->decode_bb($testo);
$testo $mklib_board->decode_smilies($testo);
}
$sezione $row['titcat'];
$icona $row['icona'];
switch($icona) {
case '1':
$image "$this->images/icona_news.gif";
    
break;
case '2':
    
$image "$this->images/icona_help.gif";
    
break;
case '3':
$image "$this->images/icona_star.gif";
    
break;
case '4':
$image "$this->images/icona_pc.gif";
    
break;
case '5':
$image "$this->images/icona_world.gif";
    
break;
    
default:
    
$image $icona;
    
break;
    
}

$pinned $row['pinned'] ? "&nbsp;<img src=\"$this->images/pin.gif\" border=\"0\" alt=\"\" />" '';
$cdata $this->create_date($row['data']);
$news_words$this->config['news_words'];
if ($this->config['news_html']) {
$testo str_replace ("<br />"" "$testo);
$testo strip_tags ($testo);
   
}
if ($news_words) {
$testo substr ($testo0$news_words);
$testo .= " ...";
   
}
        
$cont1 .= "
<table class=\"tabnews\" cellspacing=\"2\" cellpadding=\"2\" width=\"100%\">
    <tbody>
    <tr>
      <td class=\"tdblock\" align=\"center\" width=\"5%\">
      <img hspace=\"0\" src=\"$image\" align=\"bottom\" border=\"0\" alt=\"\" />
      </td>
      <td class=\"tdblock\" valign=\"top\" width=\"95%\">
      <b>$sezione<br /><a href=\"#\" rel=\"$idnt\">$titolo</a></b>$pinned
      </td>
    </tr>
    </tbody>
  </table>
  "
;
$cont .= "
 <div id=\"$idnt\">
<table class=\"tabnews\" cellspacing=\"2\" cellpadding=\"2\" width=\"100%\">
    <tbody>
    <tr>
      <td>
  <b><a href=\"http://www.isabeykoyu.com/site/index.php?ind=news&amp;op=news_show_single&amp;ide={$row['id']}\">$titolo</a></b>
  <br />
      $testo
      </td>
    </tr>
    <tr>
      <td align=\"right\">
      <br /><i>{$this->lang['from']}<b> <a href=\"$link_user=$id_orig_name\">$name</a></b>, $cdata,Bu Haber: $click Defa Okundu,<a href=\"http://www.isabeykoyu.com/site/index.php?ind=news&amp;op=submit_comment&amp;idnews={$row['id']}\">{$this->lang['comments']}</a>($totcomments), <a href=\"http://www.isabeykoyu.com/site//index.php?ind=news&amp;op=news_show_single&amp;ide={$row['id']}\">{$this->lang['readall']}</a></i>) 
      </td>
    </tr>
    </tbody>
  </table>
</div>
"
;
}
$content "
<tr>
  <td class=\"contents\">
  <div class=\"taburlo\">
    <table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"2\">
      <tr>
<td width=\"50%\" id=\"countrytabs\" class=\"taburlo\" valign=\"top\">
{$cont1}
</td>
<td width=\"50%\" class=\"taburlo\" valign=\"top\">
{$cont}
</td>
      </tr>
    </table>
  </div>
  </td>
       </tr>


<script type=\"text/javascript\">

var countries=new ddtabcontent(\"countrytabs\")
countries.setpersist(true)
countries.setselectedClassTarget(\"link\") 
countries.init()

</script>

  "
;

unset($cont1);   
unset($cont);
unset($row);
unset($idcat);
unset($categoria);
unset($idnt);
unset($query);
unset($query2);
unset($totcomments);
unset($id_orig_name);
unset($idcategoria);
unset($titolo);
unset($name);
unset($testo);
unset($sezione);
unset($icona);
unset($cdata);
unset($news_words);
                unset(
$click);




?>


 

Benzer Konular

  Konu / Başlatan Yanıt Son İleti
1 Yanıt
1386 Gösterim
Son İleti Ocak 26, 2007, 15:48:15 ÖS
Gönderen: ALpeR
8 Yanıt
1437 Gösterim
Son İleti Temmuz 05, 2008, 23:16:47 ÖS
Gönderen: isabey
2 Yanıt
3544 Gösterim
Son İleti Kasım 24, 2011, 13:11:25 ÖS
Gönderen: burajan
13 Yanıt
4644 Gösterim
Son İleti Kasım 30, 2008, 22:00:34 ÖS
Gönderen: AdmiN
3 Yanıt
1149 Gösterim
Son İleti Aralık 01, 2008, 22:03:44 ÖS
Gönderen: Boss