Toplam Üye:
32638
Aktif Üye:
0
Aktif Ziyaretçi:
694
ME_Haber 2.3 ..(110657 okuma, 145 yanıt) Resim Galerisi Modülü 2.0 ..(123214 okuma, 173 yanıt) Ustalardan Bir Ricam Olac ..(13780 okuma, 6 yanıt) nukecode.com will close ..(11317 okuma, 5 yanıt) super youtube player a lo ..(6424 okuma, 1 yanıt) Need good PHP Haber port ..(5677 okuma, 0 yanıt) Forum Nasil Tam Sayfa Olu ..(35485 okuma, 40 yanıt) Php nuke Forumu Düzenleme ..(10041 okuma, 6 yanıt) Yeni Üyelik Aktivasyon Li ..(11098 okuma, 6 yanıt) Aşk Flashları Modülü ..(7080 okuma, 2 yanıt) resim galeri 2.0 da kateg ..(11564 okuma, 9 yanıt) Yeni iki modul: Merhumlar ..(32637 okuma, 36 yanıt) ürün tanıtım modülü ..(25490 okuma, 23 yanıt) PHP Nuke is out ..(15222 okuma, 13 yanıt) MSN Video Bing Video oldu ..(5283 okuma, 0 yanıt) haberhit.com ..(5865 okuma, 1 yanıt) Bilgi Yarışması 1.0 tama ..(52643 okuma, 72 yanıt) Musıc Box elinde olan var ..(6795 okuma, 2 yanıt) Online Okey , Batak , Tav ..(175538 okuma, 340 yanıt) Emlak Modül ve Blockları ..(12451 okuma, 8 yanıt) WM who ist shampions ..(5125 okuma, 1 yanıt) coppermine resim galerisi ..(5555 okuma, 1 yanıt) Forumda Teşekkür Eklentis ..(9169 okuma, 7 yanıt) free wordpress themes ..(5647 okuma, 1 yanıt) JW image rotator for nsn ..(7757 okuma, 4 yanıt) need Iletisim module ..(11145 okuma, 8 yanıt) Yeni modul: İletişim modu ..(27935 okuma, 33 yanıt) Başvuru Modulu ve Etkinli ..(5919 okuma, 1 yanıt) world cup flash ..(5109 okuma, 0 yanıt) ..:: Php Nuke FTP link Ha ..(5002 okuma, 0 yanıt) yeni phpnuke youtube 2.0 ..(5235 okuma, 1 yanıt) Content Plus Önceki Konu ..(4834 okuma, 0 yanıt) Php nuke Tickets Modülü ..(8062 okuma, 5 yanıt) need help to news time ..(4611 okuma, 0 yanıt) NSN News v3.0 new plugin ..(4897 okuma, 0 yanıt) how to save flash as imag ..(6130 okuma, 2 yanıt) Video Blok Yardım Lütfen. ..(6061 okuma, 2 yanıt) gazete ara ..(9903 okuma, 5 yanıt) Bizim Yazarlar ve Bizim Ş ..(15117 okuma, 14 yanıt) Nuke Reflections v2 Türkç ..(14759 okuma, 14 yanıt) CNB Your Account 750 442 ..(14409 okuma, 13 yanıt) Admin panelindeki simge ç ..(12472 okuma, 9 yanıt) Hosting Modülü ..(14186 okuma, 13 yanıt) Bizim şairler Modülü ..(5270 okuma, 1 yanıt) new plugin for nsn news v ..(4820 okuma, 1 yanıt) php nuke 8.0 türkce dil s ..(7010 okuma, 3 yanıt) Kan Bankası Modül istek ..(6248 okuma, 2 yanıt) Haber Konulari Sayfasinda ..(5840 okuma, 2 yanıt) Kan Bankası Modülünde İsi ..(7156 okuma, 3 yanıt) sonhaberler flash block ..(6710 okuma, 4 yanıt)
Netopsiyon Online: Forums
Netopsiyon Online :: Başlık görüntüleniyor - Anasayfada Haberlerin Topic Resimleri Çıkmıyor...
Önceki başlık :: Sonraki başlık
Yazar
Mesaj
osman Mesaj: 50+
Kayıt: Nov 30, 2002 Mesajlar: 98
Tarih: 2005-12-06, 22:37:52 Mesaj konusu: Anasayfada Haberlerin Topic Resimleri Çıkmıyor...
Yazıyı Eklerker,Ana sayfaya Haber Modülü yerine Topics Modülü Yerleştirildiğinde Topic ile ilgili resimler çıkarken Ana sayfada haber modülü olunca Topic resimleri çıkmıyor.(hata veriyor resimler yok)...
Haber eklerken Önizleme yapıldığında sorunsuzca çıkıyor resimler.Topic resimleri doğru klasörde yer alıyor.Ana sayfada neden cıkmıyor olabilir...
Acaba News Modülünün index.php dosyasında mı bir sorun var ? Topic İmage ini gerekli adresten aldıramıyor mu acaba? Kabuk(theme) değiştirince de yine aynı sorun sürüyor...
Kod:
<?php
/************************************************************************/
/* PHP-NUKE: Web Portal System */
/* =========================== */
/* */
/* Copyright (c) 2005 by Francisco Burzi */
/* http://phpnuke.org */
/* */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License. */
/************************************************************************/
if (!defined('MODULE_FILE')) {
die ("You can't access this file directly...");
}
define('INDEX_FILE', true);
require_once("mainfile.php");
$module_name = basename(dirname(__FILE__));
get_lang($module_name);
function theindex($new_topic="0") {
global $db, $storyhome, $topicname, $topicimage, $topictext, $datetime, $user, $codddsfdsjf, $nukeurl, $prefix, $multilingual, $currentlang, $articlecomm, $sitename, $user_news, $userinfo;
if (is_user($user)) { getusrinfo($user); }
$new_topic = intval($new_topic);
if ($multilingual == 1) {
$querylang = "AND (alanguage='$currentlang' OR alanguage='')";
} else {
$querylang = "";
}
include("header.php");
automated_news();
if (isset($userinfo['setstorynum']) AND $user_news == 1) {
$storynum = $userinfo['setstorynum'];
} else {
$storynum = $storyhome;
}
if ($new_topic == 0) {
$qdb = "WHERE (ihome='0' OR catid='0')";
$home_msg = "";
} else {
$qdb = "WHERE topic='$new_topic'";
$result_a = $db->sql_query("SELECT topictext FROM ".$prefix."_topics WHERE topicid='$new_topic'");
$row_a = $db->sql_fetchrow($result_a);
$numrows_a = $db->sql_numrows($result_a);
$topic_title = filter($row_a['topictext'], "nohtml");
OpenTable();
if ($numrows_a == 0) {
echo "<center><font class=\"title\">$sitename</font><br><br>"._NOINFO4TOPIC."<br><br>[ <a href=\"modules.php?name=News\">"._GOTONEWSINDEX."</a> | <a href=\"modules.php?name=Topics\">"._SELECTNEWTOPIC."</a> ]</center>";
} else {
$db->sql_query("UPDATE ".$prefix."_topics SET counter=counter+1");
echo "<center><font class=\"title\">$sitename: $topic_title</font><br><br>"
."<form action=\"modules.php?name=Search\" method=\"post\">"
."<input type=\"hidden\" name=\"topic\" value=\"$new_topic\">"
.""._SEARCHONTOPIC.": <input type=\"name\" name=\"query\" size=\"30\"> "
."<input type=\"submit\" value=\""._SEARCH."\">"
."</form>"
."[ <a href=\"index.php\">"._GOTOHOME."</a> | <a href=\"modules.php?name=Topics\">"._SELECTNEWTOPIC."</a> ]</center>";
}
CloseTable();
echo "<br>";
}
$result = $db->sql_query("SELECT sid, catid, aid, title, time, hometext, bodytext, comments, counter, topic, informant, notes, acomm, score, ratings FROM ".$prefix."_stories $qdb $querylang ORDER BY sid DESC limit $storynum");
while ($row = $db->sql_fetchrow($result)) {
$s_sid = intval($row['sid']);
$catid = intval($row['catid']);
$aid = filter($row['aid'], "nohtml");
$title = filter($row['title'], "nohtml");
$time = $row['time'];
$hometext = filter($row['hometext']);
$bodytext = filter($row['bodytext']);
$comments = intval($row['comments']);
$counter = intval($row['counter']);
$topic = intval($row['topic']);
$informant = filter($row['informant'], "nohtml");
$notes = filter($row['notes']);
$acomm = intval($row['acomm']);
$score = intval($row['score']);
$ratings = intval($row['ratings']);
if ($catid > 0) {
$row2 = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories_cat WHERE catid='$catid'"));
$cattitle = stripslashes(check_html($row2['title'], "nohtml"));
}
getTopics($s_sid);
formatTimestamp($time);
$subject = filter($subject, "nohtml");
$introcount = strlen($hometext);
$fullcount = strlen($bodytext);
$totalcount = $introcount + $fullcount;
$c_count = $comments;
$r_options = "";
if (isset($userinfo['umode'])) { $r_options .= "&mode=".$userinfo['umode']; }
if (isset($userinfo['uorder'])) { $r_options .= "&order=".$userinfo['uorder']; }
if (isset($userinfo['thold'])) { $r_options .= "&thold=".$userinfo['thold']; }
$story_link = "<a href=\"modules.php?name=News&file=article&sid=$s_sid$r_options\">";
$morelink = "(";
if ($fullcount > 0 OR $c_count > 0 OR $articlecomm == 0 OR $acomm == 1) {
$morelink .= "$story_link<b>"._READMORE."</b></a> | ";
} else {
$morelink .= "";
}
if ($fullcount > 0) { $morelink .= "$totalcount "._BYTESMORE." | "; }
if ($articlecomm == 1 AND $acomm == 0) {
if ($c_count == 0) { $morelink .= "$story_link"._COMMENTSQ."</a>"; } elseif ($c_count == 1) { $morelink .= "$story_link$c_count "._COMMENT."</a>"; } elseif ($c_count > 1) { $morelink .= "$story_link$c_count "._COMMENTS."</a>"; }
}
$sid = intval($s_sid);
if ($catid != 0) {
$row3 = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories_cat WHERE catid='$catid'"));
$title1 = filter($row3['title'], "nohtml");
$title = "<a href=\"modules.php?name=News&file=categories&op=newindex&catid=$catid\"><font class=\"storycat\">$title1</font></a>: $title";
$morelink .= " | <a href=\"modules.php?name=News&file=categories&op=newindex&catid=$catid\">$title1</a>";
}
if ($score != 0) {
$rated = substr($score / $ratings, 0, 4);
} else {
$rated = 0;
}
$morelink .= " | "._SCORE." $rated";
$morelink .= ")";
$morelink = str_replace(" | | ", " | ", $morelink);
themeindex($aid, $informant, $datetime, $title, $counter, $topic, $hometext, $notes, $morelink, $topicname, $topicimage, $topictext);
}
include("footer.php");
}
function rate_article($sid, $score, $random_num="0", $gfx_check) {
global $prefix, $db, $ratecodddsfdsjf, $sitename, $r_options, $sitekey, $gfx_chk, $module_name;
if (isset($random_num)) {
$datekey = date("F j");
$rcode = hexdec(md5($_SERVER['HTTP_USER_AGENT'] . $sitekey . $random_num . $datekey));
$code = substr($rcode, 2, 3);
if (extension_loaded("gd") AND $code != $gfx_check AND $gfx_chk != 0) {
mt_srand ((double)microtime()*1000000);
$maxran = 1000000;
$random_num = mt_rand(0, $maxran);
include("header.php");
title("$sitename: "._ARTICLERATING."");
OpenTable();
$row = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories WHERE sid='$sid'"));
$row[title] = filter($row[title], "nohtml");
echo "<center><a href=\"modules.php?name=$module_name&file=article&sid=$sid$r_options\"><b>".$row['title']."</b></a><br>"._ARTICLERATING.": <img src=\"images/articles/stars-$score.gif\" border=\"0\" alt=\"$score/5\" title=\"$score/5\"> ($score/5)<br><br>";
echo ""._TOFINISHRATINGERROR."<br><br>";
echo "<form action=\"modules.php?name=$module_name\" method=\"post\">";
echo ""._SECURITYCODE.":<br><img src='?gfx=gfx_little&random_num=$random_num' border='1' alt='"._SECURITYCODE."' title='"._SECURITYCODE."'><br><br>\n";
echo ""._TYPESECCODE.":<br><input type=\"text\" NAME=\"gfx_check\" SIZE=\"3\" MAXLENGTH=\"3\"><br>\n";
echo "<input type=\"hidden\" name=\"random_num\" value=\"$random_num\"><br>\n";
echo "<input type=\"hidden\" name=\"score\" value=\"$score\"><br>\n";
echo "<input type=\"hidden\" name=\"sid\" value=\"$sid\">\n";
echo "<input type=\"hidden\" name=\"op\" value=\"rate_article\">";
echo "<input type=\"submit\" value=\""._CASTMYVOTE."\"></font></center></form>";
CloseTable();
include("footer.php");
die();
} else {
$score = intval($score);
$sid = intval($sid);
if ($score) {
if ($score > 5) { $score = 5; }
if ($score < 1) { $score = 1; }
if ($score != 1 AND $score != 2 AND $score != 3 AND $score != 4 AND $score != 5) {
Header("Location: index.php");
die();
}
$ip = $_SERVER['REMOTE_ADDR'];
$num = $db->sql_numrows($db->sql_query("SELECT * FROM ".$prefix."_stories WHERE sid='$sid' AND rating_ip='$ip'"));
if ($num != 0) {
Header("Location: modules.php?name=News&op=rate_complete&sid=$sid&rated=1");
die();
}
if (isset($ratecodddsfdsjf)) {
$rcodddsfdsjf = base64_decode($ratecodddsfdsjf);
$rcodddsfdsjf = addslashes($rcodddsfdsjf);
$r_codddsfdsjf = explode(":", $rcodddsfdsjf);
}
for ($i=0; $i < sizeof($r_codddsfdsjf); $i++) {
if ($r_codddsfdsjf[$i] == $sid) {
$a = 1;
}
}
if ($a == 1) {
Header("Location: modules.php?name=News&op=rate_complete&sid=$sid&rated=1");
die();
} else {
$ip = $_SERVER['REMOTE_ADDR'];
$result = $db->sql_query("update ".$prefix."_stories set score=score+$score, ratings=ratings+1, rating_ip='$ip' where sid='$sid'");
$info = base64_encode("$rcodddsfdsjf$sid:");
setcodddsfdsjf("ratecodddsfdsjf","$info",time()+86400);
update_points(7);
Header("Location: modules.php?name=News&op=rate_complete&sid=$sid&score=$score");
}
} else {
include("header.php");
title("$sitename: "._ARTICLERATING."");
OpenTable();
echo "<center>"._DIDNTRATE."<br><br>"
.""._GOBACK."</center>";
CloseTable();
include("footer.php");
}
}
} else {
mt_srand ((double)microtime()*1000000);
$maxran = 1000000;
$random_num = mt_rand(0, $maxran);
if (extension_loaded("gd") AND $gfx_chk != 0 ) {
include("header.php");
title("$sitename: "._ARTICLERATING."");
OpenTable();
$row = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories WHERE sid='$sid'"));
echo "<center><a href=\"modules.php?name=$module_name&file=article&sid=$sid$r_options\"><b>".$row['title']."</b></a><br>"._ARTICLERATING.": <img src=\"images/articles/stars-$score.gif\" border=\"0\" alt=\"$score/5\" title=\"$score/5\"> ($score/5)<br><br>";
echo ""._TOFINISHRATING."<br><br>";
echo "<form action=\"modules.php?name=$module_name\" method=\"post\">";
echo ""._SECURITYCODE.":<br><img src='?gfx=gfx_little&random_num=$random_num' border='1' alt='"._SECURITYCODE."' title='"._SECURITYCODE."'><br><br>\n";
echo ""._TYPESECCODE.":<br><input type=\"text\" NAME=\"gfx_check\" SIZE=\"3\" MAXLENGTH=\"3\"><br>\n";
echo "<input type=\"hidden\" name=\"random_num\" value=\"$random_num\"><br>\n";
echo "<input type=\"hidden\" name=\"score\" value=\"$score\"><br>\n";
echo "<input type=\"hidden\" name=\"sid\" value=\"$sid\">\n";
echo "<input type=\"hidden\" name=\"op\" value=\"rate_article\">";
echo "<input type=\"submit\" value=\""._CASTMYVOTE."\"></font></center></form>";
CloseTable();
include("footer.php");
} else {
$random_num = "$random_num";
$gfx_check = "$code";
Header("Location: modules.php?name=$module_name&op=rate_article&sid=$sid&score=$score&random_num=$random_num");
}
}
}
function rate_complete($sid, $rated=0, $score) {
global $sitename, $user, $codddsfdsjf, $module_name, $userinfo;
$r_options = "";
if (is_user($user)) {
getusrinfo($user);
if (isset($userinfo['umode'])) { $r_options .= "&mode=".$userinfo['umode']; }
if (isset($userinfo['uorder'])) { $r_options .= "&order=".$userinfo['uorder']; }
if (isset($userinfo['thold'])) { $r_options .= "&thold=".$userinfo['thold']; }
}
include("header.php");
title("$sitename: "._ARTICLERATING."");
OpenTable();
if ($rated == 0) {
$row = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories WHERE sid='$sid'"));
$row[title] = filter($row[title], "nohtml");
echo "<center><a href=\"modules.php?name=$module_name&file=article&sid=$sid$r_options\"><b>".$row['title']."</b></a><br>"._YOURATEDARTICLE.": <img src=\"images/articles/stars-$score.gif\" border=\"0\" alt=\"$score/5\" title=\"$score/5\"> ($score/5)<br><br>";
echo "<center>"._THANKSVOTEARTICLE."<br><br>"
."[ <a href=\"modules.php?name=$module_name&file=article&sid=$sid$r_options\">"._BACKTOARTICLEPAGE."</a> ]</center>";
} elseif ($rated == 1) {
echo "<center>"._ALREADYVOTEDARTICLE."<br><br>"
."[ <a href=\"modules.php?name=$module_name&file=article&sid=$sid$r_options\">"._BACKTOARTICLEPAGE."</a> ]</center>";
}
CloseTable();
include("footer.php");
}
if (!(isset($new_topic))) { $new_topic = 0; }
if (!(isset($op))) { $op = ""; }
switch ($op) {
default:
theindex($new_topic);
break;
case "rate_article":
rate_article($sid, $score, $random_num, $gfx_check);
break;
case "rate_complete":
rate_complete($sid, $rated, $score);
break;
}
?>
En son osman tarafından 2005-12-06, 23:56:41 tarihinde değiştirildi, toplam 2 kere değiştirildi
Başa dön
Bu Site Google Adsense ile Gelir Elde Ediyor
Tarih: 2024-06-14, 03:24:20 Mesaj konusu: Forum Arası Reklamlar
Başa dön
evinzencisi Mesaj: 200+
Kayıt: Nov 02, 2005 Mesajlar: 254
Tarih: 2005-12-06, 23:38:07 Mesaj konusu:
haberden tekrar düzenle ve değişikliği kaydet işlemi ikinci defa yapınca çıkıyor...bended oluyor resmin kodunu giriyorum bakıyorum ana sayfada sadece kod görünüyor...sonra tekrar düzenle dediğimde önizlemede resim görünüyor değişikliği kaydet dediğinde resim görünüyor...hatta koduda yazayım istersen
Kod:
<img height="100" hspace="3" src="site ismi/images/topics/resmin ismi.jpg" width="150" align="left" vspace="3" border="1">
değerleri kafana göre değiştirebilirsin...Kolay gelsin.
Başa dön
seyranli Mesaj: 1000+
Kayıt: May 16, 2005 Mesajlar: 3511 Konum: oradan
Tarih: 2005-12-07, 01:38:55 Mesaj konusu:
ana sayfada görünmüyosa story_home.html ye bi bakın, ya da stpry_page ne yalan söyleyim hatırlamıyom
Başa dön
osman Mesaj: 50+
Kayıt: Nov 30, 2002 Mesajlar: 98
Tarih: 2005-12-18, 04:22:51 Mesaj konusu:
Bu sorunuda Çözemedim... Arkadaşlar Etkili Bir YARDIM Lütfen... story_home.html gibi dosyalar yok...
evinzencisi bu yazdıgın kod hangi dosyada değiştirilecek???
Başa dön
KRAL_UGUR Mesaj: 500+
Kayıt: Jan 23, 2005 Mesajlar: 593 Konum: ANKARA
Tarih: 2005-12-18, 04:25:51 Mesaj konusu: Re: Anasayfada Haberlerin Topic Resimleri Çıkmıyor...
Theme klasörünün içinde story_home.html dosyası varsa buradan ana sayfada görünen haberlerin ayarlarını yapabilirsin.. Eğer yoksa theme.php dosyasında bu görevi üstlenen fonksiyonu bulup ordan gerekli değişikliği yapman gerekir...
Not: Sorununu tam olarak anlayamadığım için gerekli değişiklik diyorum...
Başa dön
osman Mesaj: 50+
Kayıt: Nov 30, 2002 Mesajlar: 98
Tarih: 2005-12-18, 04:31:33 Mesaj konusu:
Bir Konuda haber eklendiğinde haberin kategorisine göre (Topic Konusu)Ana sayfa da Haberle birlikte topic resmide cıkar.Ama bende topic resmi cıkmıyor.hata veriyor.Sanırım topic resimlerinin bulundugu yerden resim dosyasını anasayfaya cağıramıyor.bu 7,9 sürümü kullandıgımdan dolayı olabilir mi acaba?yani bu sirimde bir problem olablir mi?çünkü themes değiştirsem bile sorun devam ediyor.Themes kaynaklı bir sorun oldugunu sanmıyorum...
Başa dön
KRAL_UGUR Mesaj: 500+
Kayıt: Jan 23, 2005 Mesajlar: 593 Konum: ANKARA
Tarih: 2005-12-18, 04:34:09 Mesaj konusu:
Hmm o zaman modulden kaynaklanan bir sorun olabilir fonksiyonlardan $t_image olana bi bakmanı öneririm
Başa dön
osman Mesaj: 50+
Kayıt: Nov 30, 2002 Mesajlar: 98
Tarih: 2005-12-18, 04:35:06 Mesaj konusu: Re: Anasayfada Haberlerin Topic Resimleri Çıkmıyor...
Acaba theme.php deki bu bölümü mü değiştireceğim???
Kod:
function themeindex ($aid, $informant, $time, $title, $counter, $topic, $thetext, $notes, $morelink, $topicname, $topicimage, $topictext) {
global $anonymous, $tipath;
echo "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\"><tr><td bgcolor=\"#FFFFFF\">\n"
."<table border=\"0\" cellpadding=\"0\" cellspacing=\"1\" width=\"100%\"><tr><td bgcolor=\"#346633\">\n"
."<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\"><tr><td bgcolor=\"#346633\">\n"
."<img src=\"themes/DeepBlue/images/dot.gif\" border=\"0\"></td><td width=\"100%\" bgcolor=\"#346633\"><font class=\"option\"><b> $title</b></font></td></tr>\n"
."<tr><td colspan=\"2\" bgcolor=\"#346633\"><br>\n"
."<table border=\"0\" width=\"98%\" align=\"center\"><tr><td>\n"
."<a href=\"modules.php?name=News&new_topic=$topic\"><img src=\"$tipath$topicimage\" alt=\"$topictext\" border=\"0\" align=\"right\"></a>";
FormatStory($thetext, $notes, $aid, $informant);
echo "</td></tr></table>\n"
."</td></tr></table><br>\n"
."</td></tr><tr><td bgcolor=\"#346633\" align=\"center\">\n"
."<font class=\"tiny\">"._POSTEDBY." ";
formatAidHeader($aid);
echo " "._ON." $time $timezone ($counter "._READS.")<br></font>\n"
."<font class=\"content\">$morelink</font></center>\n"
."<img src=\"themes/DeepBlue/images/pixel.gif\" border=\"0\" height=\"2\">\n"
."</td></tr></table>\n"
."</td></tr></table><br>\n";
}
Başa dön
Bu Site Google Adsense ile Gelir Elde Ediyor
Tarih: 2024-06-14, 03:24:20 Mesaj konusu: Forum Arası Reklamlar
Başa dön
osman Mesaj: 50+
Kayıt: Nov 30, 2002 Mesajlar: 98
Tarih: 2005-12-18, 04:39:06 Mesaj konusu: Re: Anasayfada Haberlerin Topic Resimleri Çıkmıyor...
Buda News Modülünün index.php si
Kod:
<?php
/************************************************************************/
/* PHP-NUKE: Web Portal System */
/* =========================== */
/* */
/* Copyright (c) 2005 by Francisco Burzi */
/* http://phpnuke.org */
/* */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License. */
/************************************************************************/
if (!defined('MODULE_FILE')) {
die ("You can't access this file directly...");
}
define('INDEX_FILE', true);
require_once("mainfile.php");
$module_name = basename(dirname(__FILE__));
get_lang($module_name);
function theindex($new_topic="0") {
global $db, $storyhome, $topicname, $topicimage, $topictext, $datetime, $user, $codddsfdsjf, $nukeurl, $prefix, $multilingual, $currentlang, $articlecomm, $sitename, $user_news, $userinfo;
if (is_user($user)) { getusrinfo($user); }
$new_topic = intval($new_topic);
if ($multilingual == 1) {
$querylang = "AND (alanguage='$currentlang' OR alanguage='')";
} else {
$querylang = "";
}
include("header.php");
automated_news();
if (isset($userinfo['setstorynum']) AND $user_news == 1) {
$storynum = $userinfo['setstorynum'];
} else {
$storynum = $storyhome;
}
if ($new_topic == 0) {
$qdb = "WHERE (ihome='0' OR catid='0')";
$home_msg = "";
} else {
$qdb = "WHERE topic='$new_topic'";
$result_a = $db->sql_query("SELECT topictext FROM ".$prefix."_topics WHERE topicid='$new_topic'");
$row_a = $db->sql_fetchrow($result_a);
$numrows_a = $db->sql_numrows($result_a);
$topic_title = filter($row_a['topictext'], "nohtml");
OpenTable();
if ($numrows_a == 0) {
echo "<center><font class=\"title\">$sitename</font><br><br>"._NOINFO4TOPIC."<br><br>[ <a href=\"modules.php?name=News\">"._GOTONEWSINDEX."</a> | <a href=\"modules.php?name=Topics\">"._SELECTNEWTOPIC."</a> ]</center>";
} else {
$db->sql_query("UPDATE ".$prefix."_topics SET counter=counter+1");
echo "<center><font class=\"title\">$sitename: $topic_title</font><br><br>"
."<form action=\"modules.php?name=Search\" method=\"post\">"
."<input type=\"hidden\" name=\"topic\" value=\"$new_topic\">"
.""._SEARCHONTOPIC.": <input type=\"name\" name=\"query\" size=\"30\"> "
."<input type=\"submit\" value=\""._SEARCH."\">"
."</form>"
."[ <a href=\"index.php\">"._GOTOHOME."</a> | <a href=\"modules.php?name=Topics\">"._SELECTNEWTOPIC."</a> ]</center>";
}
CloseTable();
echo "<br>";
}
$result = $db->sql_query("SELECT sid, catid, aid, title, time, hometext, bodytext, comments, counter, topic, informant, notes, acomm, score, ratings FROM ".$prefix."_stories $qdb $querylang ORDER BY sid DESC limit $storynum");
while ($row = $db->sql_fetchrow($result)) {
$s_sid = intval($row['sid']);
$catid = intval($row['catid']);
$aid = filter($row['aid'], "nohtml");
$title = filter($row['title'], "nohtml");
$time = $row['time'];
$hometext = filter($row['hometext']);
$bodytext = filter($row['bodytext']);
$comments = intval($row['comments']);
$counter = intval($row['counter']);
$topic = intval($row['topic']);
$informant = filter($row['informant'], "nohtml");
$notes = filter($row['notes']);
$acomm = intval($row['acomm']);
$score = intval($row['score']);
$ratings = intval($row['ratings']);
if ($catid > 0) {
$row2 = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories_cat WHERE catid='$catid'"));
$cattitle = stripslashes(check_html($row2['title'], "nohtml"));
}
getTopics($s_sid);
formatTimestamp($time);
$subject = filter($subject, "nohtml");
$introcount = strlen($hometext);
$fullcount = strlen($bodytext);
$totalcount = $introcount + $fullcount;
$c_count = $comments;
$r_options = "";
if (isset($userinfo['umode'])) { $r_options .= "&mode=".$userinfo['umode']; }
if (isset($userinfo['uorder'])) { $r_options .= "&order=".$userinfo['uorder']; }
if (isset($userinfo['thold'])) { $r_options .= "&thold=".$userinfo['thold']; }
$story_link = "<a href=\"modules.php?name=News&file=article&sid=$s_sid$r_options\">";
$morelink = "(";
if ($fullcount > 0 OR $c_count > 0 OR $articlecomm == 0 OR $acomm == 1) {
$morelink .= "$story_link<b>"._READMORE."</b></a> | ";
} else {
$morelink .= "";
}
if ($fullcount > 0) { $morelink .= "$totalcount "._BYTESMORE." | "; }
if ($articlecomm == 1 AND $acomm == 0) {
if ($c_count == 0) { $morelink .= "$story_link"._COMMENTSQ."</a>"; } elseif ($c_count == 1) { $morelink .= "$story_link$c_count "._COMMENT."</a>"; } elseif ($c_count > 1) { $morelink .= "$story_link$c_count "._COMMENTS."</a>"; }
}
$sid = intval($s_sid);
if ($catid != 0) {
$row3 = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories_cat WHERE catid='$catid'"));
$title1 = filter($row3['title'], "nohtml");
$title = "<a href=\"modules.php?name=News&file=categories&op=newindex&catid=$catid\"><font class=\"storycat\">$title1</font></a>: $title";
$morelink .= " | <a href=\"modules.php?name=News&file=categories&op=newindex&catid=$catid\">$title1</a>";
}
if ($score != 0) {
$rated = substr($score / $ratings, 0, 4);
} else {
$rated = 0;
}
$morelink .= " | "._SCORE." $rated";
$morelink .= ")";
$morelink = str_replace(" | | ", " | ", $morelink);
themeindex($aid, $informant, $datetime, $title, $counter, $topic, $hometext, $notes, $morelink, $topicname, $topicimage, $topictext);
}
include("footer.php");
}
function rate_article($sid, $score, $random_num="0", $gfx_check) {
global $prefix, $db, $ratecodddsfdsjf, $sitename, $r_options, $sitekey, $gfx_chk, $module_name;
if (isset($random_num)) {
$datekey = date("F j");
$rcode = hexdec(md5($_SERVER['HTTP_USER_AGENT'] . $sitekey . $random_num . $datekey));
$code = substr($rcode, 2, 3);
if (extension_loaded("gd") AND $code != $gfx_check AND $gfx_chk != 0) {
mt_srand ((double)microtime()*1000000);
$maxran = 1000000;
$random_num = mt_rand(0, $maxran);
include("header.php");
title("$sitename: "._ARTICLERATING."");
OpenTable();
$row = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories WHERE sid='$sid'"));
$row[title] = filter($row[title], "nohtml");
echo "<center><a href=\"modules.php?name=$module_name&file=article&sid=$sid$r_options\"><b>".$row['title']."</b></a><br>"._ARTICLERATING.": <img src=\"images/articles/stars-$score.gif\" border=\"0\" alt=\"$score/5\" title=\"$score/5\"> ($score/5)<br><br>";
echo ""._TOFINISHRATINGERROR."<br><br>";
echo "<form action=\"modules.php?name=$module_name\" method=\"post\">";
echo ""._SECURITYCODE.":<br><img src='?gfx=gfx_little&random_num=$random_num' border='1' alt='"._SECURITYCODE."' title='"._SECURITYCODE."'><br><br>\n";
echo ""._TYPESECCODE.":<br><input type=\"text\" NAME=\"gfx_check\" SIZE=\"3\" MAXLENGTH=\"3\"><br>\n";
echo "<input type=\"hidden\" name=\"random_num\" value=\"$random_num\"><br>\n";
echo "<input type=\"hidden\" name=\"score\" value=\"$score\"><br>\n";
echo "<input type=\"hidden\" name=\"sid\" value=\"$sid\">\n";
echo "<input type=\"hidden\" name=\"op\" value=\"rate_article\">";
echo "<input type=\"submit\" value=\""._CASTMYVOTE."\"></font></center></form>";
CloseTable();
include("footer.php");
die();
} else {
$score = intval($score);
$sid = intval($sid);
if ($score) {
if ($score > 5) { $score = 5; }
if ($score < 1) { $score = 1; }
if ($score != 1 AND $score != 2 AND $score != 3 AND $score != 4 AND $score != 5) {
Header("Location: index.php");
die();
}
$ip = $_SERVER['REMOTE_ADDR'];
$num = $db->sql_numrows($db->sql_query("SELECT * FROM ".$prefix."_stories WHERE sid='$sid' AND rating_ip='$ip'"));
if ($num != 0) {
Header("Location: modules.php?name=News&op=rate_complete&sid=$sid&rated=1");
die();
}
if (isset($ratecodddsfdsjf)) {
$rcodddsfdsjf = base64_decode($ratecodddsfdsjf);
$rcodddsfdsjf = addslashes($rcodddsfdsjf);
$r_codddsfdsjf = explode(":", $rcodddsfdsjf);
}
for ($i=0; $i < sizeof($r_codddsfdsjf); $i++) {
if ($r_codddsfdsjf[$i] == $sid) {
$a = 1;
}
}
if ($a == 1) {
Header("Location: modules.php?name=News&op=rate_complete&sid=$sid&rated=1");
die();
} else {
$ip = $_SERVER['REMOTE_ADDR'];
$result = $db->sql_query("update ".$prefix."_stories set score=score+$score, ratings=ratings+1, rating_ip='$ip' where sid='$sid'");
$info = base64_encode("$rcodddsfdsjf$sid:");
setcodddsfdsjf("ratecodddsfdsjf","$info",time()+86400);
update_points(7);
Header("Location: modules.php?name=News&op=rate_complete&sid=$sid&score=$score");
}
} else {
include("header.php");
title("$sitename: "._ARTICLERATING."");
OpenTable();
echo "<center>"._DIDNTRATE."<br><br>"
.""._GOBACK."</center>";
CloseTable();
include("footer.php");
}
}
} else {
mt_srand ((double)microtime()*1000000);
$maxran = 1000000;
$random_num = mt_rand(0, $maxran);
if (extension_loaded("gd") AND $gfx_chk != 0 ) {
include("header.php");
title("$sitename: "._ARTICLERATING."");
OpenTable();
$row = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories WHERE sid='$sid'"));
echo "<center><a href=\"modules.php?name=$module_name&file=article&sid=$sid$r_options\"><b>".$row['title']."</b></a><br>"._ARTICLERATING.": <img src=\"images/articles/stars-$score.gif\" border=\"0\" alt=\"$score/5\" title=\"$score/5\"> ($score/5)<br><br>";
echo ""._TOFINISHRATING."<br><br>";
echo "<form action=\"modules.php?name=$module_name\" method=\"post\">";
echo ""._SECURITYCODE.":<br><img src='?gfx=gfx_little&random_num=$random_num' border='1' alt='"._SECURITYCODE."' title='"._SECURITYCODE."'><br><br>\n";
echo ""._TYPESECCODE.":<br><input type=\"text\" NAME=\"gfx_check\" SIZE=\"3\" MAXLENGTH=\"3\"><br>\n";
echo "<input type=\"hidden\" name=\"random_num\" value=\"$random_num\"><br>\n";
echo "<input type=\"hidden\" name=\"score\" value=\"$score\"><br>\n";
echo "<input type=\"hidden\" name=\"sid\" value=\"$sid\">\n";
echo "<input type=\"hidden\" name=\"op\" value=\"rate_article\">";
echo "<input type=\"submit\" value=\""._CASTMYVOTE."\"></font></center></form>";
CloseTable();
include("footer.php");
} else {
$random_num = "$random_num";
$gfx_check = "$code";
Header("Location: modules.php?name=$module_name&op=rate_article&sid=$sid&score=$score&random_num=$random_num");
}
}
}
function rate_complete($sid, $rated=0, $score) {
global $sitename, $user, $codddsfdsjf, $module_name, $userinfo;
$r_options = "";
if (is_user($user)) {
getusrinfo($user);
if (isset($userinfo['umode'])) { $r_options .= "&mode=".$userinfo['umode']; }
if (isset($userinfo['uorder'])) { $r_options .= "&order=".$userinfo['uorder']; }
if (isset($userinfo['thold'])) { $r_options .= "&thold=".$userinfo['thold']; }
}
include("header.php");
title("$sitename: "._ARTICLERATING."");
OpenTable();
if ($rated == 0) {
$row = $db->sql_fetchrow($db->sql_query("SELECT title FROM ".$prefix."_stories WHERE sid='$sid'"));
$row[title] = filter($row[title], "nohtml");
echo "<center><a href=\"modules.php?name=$module_name&file=article&sid=$sid$r_options\"><b>".$row['title']."</b></a><br>"._YOURATEDARTICLE.": <img src=\"images/articles/stars-$score.gif\" border=\"0\" alt=\"$score/5\" title=\"$score/5\"> ($score/5)<br><br>";
echo "<center>"._THANKSVOTEARTICLE."<br><br>"
."[ <a href=\"modules.php?name=$module_name&file=article&sid=$sid$r_options\">"._BACKTOARTICLEPAGE."</a> ]</center>";
} elseif ($rated == 1) {
echo "<center>"._ALREADYVOTEDARTICLE."<br><br>"
."[ <a href=\"modules.php?name=$module_name&file=article&sid=$sid$r_options\">"._BACKTOARTICLEPAGE."</a> ]</center>";
}
CloseTable();
include("footer.php");
}
if (!(isset($new_topic))) { $new_topic = 0; }
if (!(isset($op))) { $op = ""; }
switch ($op) {
default:
theindex($new_topic);
break;
case "rate_article":
rate_article($sid, $score, $random_num, $gfx_check);
break;
case "rate_complete":
rate_complete($sid, $rated, $score);
break;
}
?>
Başa dön
KRAL_UGUR Mesaj: 500+
Kayıt: Jan 23, 2005 Mesajlar: 593 Konum: ANKARA
Tarih: 2005-12-18, 04:42:36 Mesaj konusu:
$tipath yazan yeri images/topics/ olarak deiştirmeyi bi deneyin
olmayabilir emin deilim....
Başa dön
osman Mesaj: 50+
Kayıt: Nov 30, 2002 Mesajlar: 98
Tarih: 2005-12-18, 04:46:25 Mesaj konusu:
değişen bi şey olmadı malesef
Başa dön
Aliosman Teknik Yönetici
Kayıt: Jul 20, 2002 Mesajlar: 3836 Konum: Balıkesir
Tarih: 2005-12-18, 04:49:46 Mesaj konusu:
config.php dosyanızı kontrol edin. Orada images/topics/ olarak tanımlı mı? ayrıca mainfile.php yi açın. Orada images/topics/ olarak tanımlı olup olmadığına bakın. Dikkatli bakın. Çünkü bu satırlar aynı yazdığım gibi olacak. Yani sonunda topics/ de olduğu gibi / olmalı. Ayrıca konu grafiklerinizi yönetimden ve ftpden kontrol edin. Uzantılarına dikkat edin. GIF ile gif uzantıları isimleri aynı olsa bile 2 farklı grafik demektir.
Başa dön
osman Mesaj: 50+
Kayıt: Nov 30, 2002 Mesajlar: 98
Tarih: 2005-12-18, 04:56:59 Mesaj konusu:
config de aynen dediğiniz gibi var...ancak mainfile.php de yok...ne yapmam lazım?nasıl eklicem ne şekilde?
Yeniden düzenle dediğimde düzenleme sayfasının ön izlemesinde doğru şekilde çıkıyor ancak bu anasayfaya yansımıyor....
Başa dön
Aliosman Teknik Yönetici
Kayıt: Jul 20, 2002 Mesajlar: 3836 Konum: Balıkesir
Tarih: 2005-12-18, 05:05:41 Mesaj konusu:
mainfile.php nerden çıktı ya? Aklım başka soruya takıldı sanırım. Orda olmaması normal.
Dosyalarınız kontrol ettiniz mi? images/topics klasörü altında konu grafikleriniz duruyor mu? phpnuke.gif ile phpnuke.GIF 2 farklı dosyadır demiştim. Onu kontrol ettiniz mi? Bence sorun bu.
Başka bir çözüm yolu. temanızda verdiğiniz alanda global $anonymous, $tipath; satırının hemen altına şunu ekle.
$tipath="images/topics/";
Bu da hata verirse (sayfayı yenilemeyi ve cahce temizlemeyi unutma) o zaman veritabanında problem var. phpmyadmini açın. Bütün tabloarınızı seçin ve onar işlemini uygulayın.
Başa dön
KRAL_UGUR Mesaj: 500+
Kayıt: Jan 23, 2005 Mesajlar: 593 Konum: ANKARA
Tarih: 2005-12-18, 05:18:04 Mesaj konusu:
Ya konuyu dağıtmak istemem ama şu onar ne işe yarıyo yani ne yapıyo veri tabanına ... tekrar mı kaldırıp kuruyo yada ne bileyim eski haline mi getirio ...
Başa dön
Aliosman Teknik Yönetici
Kayıt: Jul 20, 2002 Mesajlar: 3836 Konum: Balıkesir
Tarih: 2005-12-18, 05:31:09 Mesaj konusu:
Onar işlemi aslında önemli bir özellik. Sürekli veri girilen, silinen yada güncellenen veritabanı tabloları belli bir süre sonra gereksiz veri kalıntılarla kalıyor ve bozuluyor. Onar (REPAIR) bu bozulan veritabanı tablolarını düzeltiyor ve ayrıca gereksiz veri kalıntılarını temizliyor, bir nevi disk optimizasyonu gibi çalışıyor. Böylece sql sorguları hızlanıyor, bu da sitenin hızını etkiliyor.
Örneğin netopsiyon.com da cron tanımlı. Bununla 12 saatte bir veritabanlarının tamamı repair işlemine tabii tutuluyor.
Başa dön
osman Mesaj: 50+
Kayıt: Nov 30, 2002 Mesajlar: 98
Tarih: 2005-12-18, 05:32:08 Mesaj konusu:
ekledim değişen bi şey yok. theme de sorun yok sanırım. çünkü başka tehmes kullanıncada aynı sorunu yapıyor...bu arada grafik yerleri doğru
Başa dön
KRAL_UGUR Mesaj: 500+
Kayıt: Jan 23, 2005 Mesajlar: 593 Konum: ANKARA
Tarih: 2005-12-18, 05:34:30 Mesaj konusu:
Tşkler webmaster birazdan sitemin databasini onarcam baya yawaşlamıştı bende diom neden çok saol ;)
Başa dön
Aliosman Teknik Yönetici
Kayıt: Jul 20, 2002 Mesajlar: 3836 Konum: Balıkesir
Tarih: 2005-12-18, 05:34:38 Mesaj konusu:
Yönetimden konular yönetimine girin. Orada grafiklerinizi görebiliyor musunuz?
***Bu da hata verirse (sayfayı yenilemeyi ve cahce temizlemeyi unutma) o zaman veritabanında problem var. phpmyadmini açın. Bütün tabloarınızı seçin ve onar işlemini uygulayın.
Başa dön
osman Mesaj: 50+
Kayıt: Nov 30, 2002 Mesajlar: 98
Tarih: 2005-12-18, 05:42:28 Mesaj konusu:
orada görüyorum.hatta konuyu editlediğimde önizleme dede resimler görünüyor.ama anasayfaya cıkmıyor
Başa dön
KRAL_UGUR Mesaj: 500+
Kayıt: Jan 23, 2005 Mesajlar: 593 Konum: ANKARA
Tarih: 2005-12-18, 05:45:49 Mesaj konusu:
Ana sayfadaki resimi sağ tıklayınca adres tam olarak nasıl buraya bi yazabilirmisin hani çarpı olarak çıkıyo ya ona sağ tıklayıp bi özellikler de sonra adresi buraya yaz ...
Başa dön
osman Mesaj: 50+
Kayıt: Nov 30, 2002 Mesajlar: 98
Başa dön
Aliosman Teknik Yönetici
Kayıt: Jul 20, 2002 Mesajlar: 3836 Konum: Balıkesir
Başa dön
osman Mesaj: 50+
Kayıt: Nov 30, 2002 Mesajlar: 98
Başa dön
evinzencisi Mesaj: 200+
Kayıt: Nov 02, 2005 Mesajlar: 254
Tarih: 2005-12-18, 15:58:30 Mesaj konusu: Re: Anasayfada Haberlerin Topic Resimleri Çıkmıyor...
Eğer anladığım şeyse yardımcı olayım haberlerin yanında ki topic resimlerine tıklayınca haberin devamı görünsün diyorsun.Thema içerisinde story_page.html diye bir dosya vardır onu aç şu kodu bul...
Kod:
<td width="22" bgcolor="FFFFFF"><a href="modules.php?name=News&new_topic=$topic"><img src="$tipath$topicimage" border="0" alt="$topictext" title="$topictext" align="left" hspace="10" vspace="10"></a></td>
benimkinde align="left" diyor seninkinde muhtemelen align="right" tır. Herneyse buradaki linki değiştirerek yapabilirsin.veya bu kodu silerek topic resmini hepten çıkarabilirsin.
Başa dön
Bu forumda yeni başlıklar açamazsınız Bu forumdaki başlıklara cevap veremezsiniz Bu forumdaki mesajlarınızı değiştiremezsiniz Bu forumdaki mesajlarınızı silemezsiniz Bu forumdaki anketlerde oy kullanamazsınız