Odstranenie noviniek z phpfusion
Ahojte, prednedávnom som uvažoval, ako odstránim novinky z php fusion. Potreboval som dizajn s administráciou, najvhodnejší bol php fusion, tak som si ho zvolil. No čo čert nečakal, nevedel som si dať rady s novinkami na hlavnej stránke. Keď som tak už mal nervy spravil som nasledovné:
Krok č.:1
Staci si otvorit subor theme.php a vymazat z neho riadky:
function render_news($subject, $news, $info) {
echo "<table cellpadding='0' cellspacing='0' width='100%'>
<tr>
<td class='capmain'>$subject</td>
</tr>
<tr>
<td class='main-body'>$news</td>
</tr>
<tr>
<td align='left' class='news-footer'>\n";
echo " Pridal: <a href='profile.php?lookup=".$info['user_id']."'>".$info['user_name']."</a>";
echo ", <a href='news.php?readmore=".$info['news_id']."'>Komentáre (".$info['news_comments'].")</a>";
echo ", Prečítané ".$info['news_reads']."x";
echo ", <a href='news.php?readmore=".$info['news_id']."'><b><span style='color:#c99e43'>Čítaj celé</span></a>";
echo "</tr>
</table>\n";
}
Krok č.:2
nasledne si otvorit subor news.php v korenovom adresary php fusionu a pastnut tam tieto riadky:
<?php
/*-------------------------------------------------------+
| PHP-Fusion Content Management System
| Copyright (C) 2002 - 2010 Nick Jones
| http://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: news.php
| Author: Nick Jones (Digitanium)
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
require_once "maincore.php";
require_once THEMES."templates/header.php";
// Predefined variables, do not edit these values
if ($settings['news_style'] == "1") { $i = 0; $rc = 0; $ncount = 1; $ncolumn = 1; $news_[0] = ""; $news_[1] = ""; $news_[2] = ""; } else { $i = 1; }
// Number of news displayed
$items_per_page = $settings['newsperpage'];
require_once THEMES."templates/footer.php";
?>
!POZOR! Pri pridávaní novinky cez administráciu vyhodí systém chybovú hlášku a novinku nepridá!
Krok č.:1
Staci si otvorit subor theme.php a vymazat z neho riadky:
function render_news($subject, $news, $info) {
echo "<table cellpadding='0' cellspacing='0' width='100%'>
<tr>
<td class='capmain'>$subject</td>
</tr>
<tr>
<td class='main-body'>$news</td>
</tr>
<tr>
<td align='left' class='news-footer'>\n";
echo " Pridal: <a href='profile.php?lookup=".$info['user_id']."'>".$info['user_name']."</a>";
echo ", <a href='news.php?readmore=".$info['news_id']."'>Komentáre (".$info['news_comments'].")</a>";
echo ", Prečítané ".$info['news_reads']."x";
echo ", <a href='news.php?readmore=".$info['news_id']."'><b><span style='color:#c99e43'>Čítaj celé</span></a>";
echo "</tr>
</table>\n";
}
Krok č.:2
nasledne si otvorit subor news.php v korenovom adresary php fusionu a pastnut tam tieto riadky:
<?php
/*-------------------------------------------------------+
| PHP-Fusion Content Management System
| Copyright (C) 2002 - 2010 Nick Jones
| http://www.php-fusion.co.uk/
+--------------------------------------------------------+
| Filename: news.php
| Author: Nick Jones (Digitanium)
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
require_once "maincore.php";
require_once THEMES."templates/header.php";
// Predefined variables, do not edit these values
if ($settings['news_style'] == "1") { $i = 0; $rc = 0; $ncount = 1; $ncolumn = 1; $news_[0] = ""; $news_[1] = ""; $news_[2] = ""; } else { $i = 1; }
// Number of news displayed
$items_per_page = $settings['newsperpage'];
require_once THEMES."templates/footer.php";
?>
!POZOR! Pri pridávaní novinky cez administráciu vyhodí systém chybovú hlášku a novinku nepridá!
Komentáre
Pridať komentár
Pre pridanie komentára musíte byť prihlásený.
Hodnotenia
Musíte byť zaregistrovaný, aby ste mohli hodnotiť.
Prosím prihláste, alebo sa zaregistrujte.
Prosím prihláste, alebo sa zaregistrujte.
Zatial nikto neohodnotil tento príspevok.







Či?