• 18-05-2008, 13:44:43
    #1
    Arkadaşlar İçerik Siteme Ekleyen Kişi Diye 1 Eklenti Yapmak İstiyorum..

    phpmyadmin de içerikler tablosune ekleyen diye 1 değişken ekledim

    admin panelinden ekleyen diye ekliyorum phpmyadminde tabloya ekliyor yalnız gösterimde yani içeriğin sitede göstermek istediğim zaman görünmüyor.

    Ekleyen Diye Makale Başlığı Çıkıyor Acaba Değişkenleri Tam Olarak Nereye Eklemem Gereken

    Ekleyen Değişkeni

    $ekleyen



    Makale Deyay.php kodunde ekleyen diye aratırsanız değişkenleri nereye eklediğimi görürsünüz acaba nerede hata yapıyorum?

    <?php
     
    function get_kundir($link)
    {
        $link = trim($link);
        $link = strtolower($link);
        $find = array('<b>', '</b>');
        $link = str_replace ($find, '', $link);
        $link = preg_replace('/<(\/{0,1})img(.*?)(\/{0,1})\>/', 'image', $link);
        $find = array(' ', '&quot;', '&amp;', '&', '\r\n', '\n', '/', '\\', '+', '<', '>');
        $link = str_replace ($find, '-', $link);
        $find = array('é', 'è', 'ë', 'ê', 'É', 'È', 'Ë', 'Ê');
        $link = str_replace ($find, 'e', $link);
        $find = array('í', 'ì', 'î', 'ï', 'I', 'ı', 'Í', 'Ì', 'Î', 'Ï');
        $link = str_replace ($find, 'i', $link);
        $find = array('ó', 'ö', 'Ö', 'ò', 'ô', 'Ó', 'Ò', 'Ô');
        $link = str_replace ($find, 'o', $link);
        $find = array('á', 'ä', 'â', 'à', 'â', 'Ä', 'Â', 'Á', 'À', 'Â');
        $link = str_replace ($find, 'a', $link);
        $find = array('ú', 'ü', 'Ü', 'ù', 'û', 'Ú', 'Ù', 'Û');
        $link = str_replace ($find, 'u', $link);
        $find = array('ç', 'Ç');
        $link = str_replace ($find, 'c', $link);
        $find = array('ş');
        $link = str_replace ($find, 's', $link);
        $find = array('ğ');
        $link = str_replace ($find, 'g', $link);
        $find = array('/[^a-z0-9\-<>]/', '/[\-]+/', '/<[^>]*>/');
        $repl = array('', '-', '');
        $link = preg_replace ($find, $repl, $link);
        $link = str_replace ('--', '-', $link);
        return $link;
    }
    include("ayarlar.php");
    include("veritablosu.php");
    $makale_id=$_GET["makale_id"];
    $makaleadicek=@mysql_query("select baslik from "._BURAK."makaleler where id='$makale_id'");
    list($makaleadi)=@mysql_fetch_row($makaleadicek);
    temaac("$makaleadi - MsnDiyari.CoM");
    sayfaac("$makaleadi ");
    $makalelericek=@mysql_query("select id, baslik, icerik, tarih, okunma, oy, ekleyen, oykullanan, tag from "._BURAK."makaleler where id='$makale_id'");
    while($gosterbakalim = @mysql_fetch_array($makalelericek)) 
    {
     $makale_id = $gosterbakalim["id"];
     $icerik = stripslashes($gosterbakalim["icerik"]);
     $ekleyen=stripslashes($ekleyen);
     $baslik2 = strtolower(stripslashes(strtr($baslik2,"ÜŞÇİĞÖüöşçiğı?%","USCIGOuoscigi-,"))); 
    $baslik2 = str_replace(" ","-",$baslik2);
     $baslik = stripslashes($gosterbakalim["baslik"]);
     
     $tarihdata=stripslashes($gosterbakalim["tarih"]);
     $tarih1 = explode("-", $tarihdata); 
     $tarih= $tarih1[2] . "." .$tarih1[1]. "." .$tarih1[0];
     $okunma = stripslashes($gosterbakalim["okunma"]);
     if($gosterbakalim["oy"] > 0 )
      $oy= round($gosterbakalim["oy"] / $gosterbakalim["oykullanan"],2); 
     else
      $oy=0;
     $baslik1=stripslashes($baslik);
     $baslik1 = strtolower(stripslashes(strtr($baslik1,"ÜŞÇİĞÖüöşçiğı?%","USCIGOuoscigi-,"))); 
    $baslik1 = str_replace(" ","-",$baslik1);
    $hitarttir=@mysql_query("update "._BURAK."makaleler set okunma=okunma+1 where id='$makale_id'"); 
    ?>
    <table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#FFFFFF" width="100%" height="84">
      <tr>
        <td width="28%" height="24"><b>&nbsp; İçerik Adı</b></td>
        <td width="3%" height="24" align="center"><b>:</b></td>
        <td width="69%" height="24">&nbsp; <?=$baslik?></td>
      </tr>
      <tr>
        <td width="28%" height="24"><b>&nbsp; Eklenme Tarihi</b></td>
        <td width="3%" height="24" align="center"><b>:</b></td>
        <td width="69%" height="24">&nbsp; <?=$tarih?></td>
      </tr>
      <tr>
        <td width="28%" height="24"><b>&nbsp; Oynanma Sayısı</b></td>
        <td width="3%" height="24" align="center"><b>:</b></td>
        <td width="69%" height="24">&nbsp; <?=$okunma?></td>
      </tr>
      <tr>
        <td width="100%" height="1" colspan="3">
        <table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="100%" height="1">
          <tr>
            <td width="28%" height="1"><b>&nbsp; Ortalama Puan</b></td>
            <td width="3%" height="1">
            <p align="center"><b>:</b></td>
            <td width="19%" height="24">
            <p align="center"><?php
    for($i=1; $i<=$oy; $i++) echo"<img src="https://www.r10.net/php/._SITEURL."/resimler/hot.gif alt=\"10 UZERINDEN $oy\">";
      for($j=$i; $j<=10; $j++) echo"<img src="https://www.r10.net/php/._SITEURL."/resimler/nothot.gif alt=\"10 UZERINDEN $oy\">"; 
    ?></td><form action="<?=_SITEURL?>/vote-action/<?=$makale_id?>/<?=$baslik1?>.html" method="post">
            <td width="19%" align="center" height="1"><b>Puan Ver?</b></td>
            <td width="2%" align="center" height="1"><b>:</b></td>
            <td width="11%" align="center" height="1"><select size="1" name="oy"><?php
     for ($oylamayazdirdik=10; $oylamayazdirdik>=1; $oylamayazdirdik--) echo"<option>$oylamayazdirdik</option>
            "; 
     ?></select></td>
            <td width="18%" align="center" height="1"><input type="submit" value="Puan Ver"></td></form>
          </tr>
        </table>
        </td>
      </tr>
      <tr>
        <td width="100%" height="24" colspan="3" background="<?=_SITEURL?>/resimler/sayfabaslik.jpg">
        <b>&nbsp; İçerik</b></td>
      </tr>
      <tr>
        <td width="100%" height="73" colspan="3">
        <table border="0" cellpadding="0" cellspacing="5" style="border-collapse: collapse" bordercolor="#111111" width="100%" height="100%">
          <tr>
            <td width="100%" valign="top"><p align="center"><script type="text/javascript"><!--
    google_ad_client = "pub-5426479490228973";
    /* 300x250, oluşturulma 03.05.2008 */
    google_ad_slot = "8405646958";
    google_ad_width = 300;
    google_ad_height = 250;
    //-->
    </script>
    <script type="text/javascript"
    src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
    </script><script type="text/javascript"><!--
    google_ad_client = "pub-5426479490228973";
    /* 300x250, oluşturulma 03.05.2008 */
    google_ad_slot = "8405646958";
    google_ad_width = 300;
    google_ad_height = 250;
    //-->
    </script>
    <script type="text/javascript"
    src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
    </script></p>
    <?php echo html_entity_decode(stripslashes($icerik));?><br>Tags:<?php
    $parcala = explode(',', $gosterbakalim[tag]); 
    for($i=0; $i<count($parcala); $i++){ 
    $kelime = $parcala[$i]; 
    echo "<a href="https://www.r10.net/php/._SITEURL."/tag/".get_kundir($kelime)."/> $kelime&nbsp; </a>"; 
    }  
     ?><br>Ekleyen:<?=$baslik?><br>
    <script type="text/javascript"><!--
    google_ad_client = "pub-5426479490228973";
    /* 468x15, oluşturulma 03.05.2008 */
    google_ad_slot = "1235692527";
    google_ad_width = 468;
    google_ad_height = 15;
    //-->
    </script>
    <script type="text/javascript"
    src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
    </script></td>
          </tr>
       <tr>
            <td width="100%" valign="top"></td>
          </tr>
        </table>
        </td>
      </tr>
    </table>
    <?
    }
    sayfakapat();
    temakapat();
    ?>
  • 18-05-2008, 16:11:41
    #2
    $ekleyen=stripslashes($ekleyen);
    Bunun yerine
    $ekleyen=stripslashes($gosterbakalim['ekleyen']);
    deenemelisin arkadasim Kolay Gelsin
  • 18-05-2008, 17:44:20
    #3
    @GaziSoft

    Hocam Olmadı Ya. Ben Gösterme Kısmında İse Şu Kodu Kullanıyorum


    Örnek;
    http://www.msndiyari.com/msn/1640/deneme.html

    Ekleyen:<?php (stripslashes($ekleyen));?>
  • 18-05-2008, 18:34:40
    #4
    benim kodu denedinizmi?
  • 18-05-2008, 18:46:07
    #5
    evet Denedim Olmadı
  • 18-05-2008, 19:47:58
    #6
    Girindir Hocam isterseniz ferdikucuk@msn.com Ekleyin detayli Goruselim.Bir hayli uykum var