Bravo List
Register
Go Back   > Bravo List > Source Code > Archived Trackers > Template Shares
Reply
  #1  
Old 11th November 2013, 17:01
open open is offline
Senior Member
 
Join Date: Nov 2010
P2P
Posts: 22
Red face plugin news
Hello

I would put the news plugin on one page instead of being on the index! .....

someone could you help me because the tests I created does not work

thank you

PHP Code:
<?php
require_once 'global.php';

  
gzip ();
  
dbconn ();
  
loggedinorreturn ();
  
maxsysop ();
  
parked ();
  
define ('T_VERSION''v.0.7 by xam');
stdhead ('Nouvelles');

# Settings
$news ''//Must be empty and same as plugin and file name.
if (!defined('SKIP_CACHE_MESSAGE'))
{
    
define('SKIP_CACHE_MESSAGE'true);
}
require_once(
INC_PATH.'/functions_cache2.php');
if (!(
$newscached cache_check2('news')))
{    
    
# Query
    
$news_query sql_query('SELECT added, body, title FROM news ORDER BY added DESC LIMIT 0,'.MAX_NEWS);
    if (
mysql_num_rows($news_query) > 0)
    {
        while(
$news_results mysql_fetch_assoc($news_query))
        {
            
$news .= '<span class="subheader"><strong>'.$news_results['title'].' - '.my_datee($dateformat$news_results['added']).' '.my_datee($timeformat$news_results['added']).'</strong></span><hr />'.format_comment($news_results['body']).(MAX_NEWS '<br /><br />' '');
        }
    }
    
cache_save2('news'$news);
}
else
{
    
$news .= ($is_mod '<span style="float: right;">[<a href="'.$BASEURL.'/admin/index.php?act=news">'.$lang->index['newspage'].'</a>]</span><br /><hr />' '<hr />');
    
$news .= $newscached;
}

stdfoot ();
?>
Bump: person to help?
Attached Files
File Type: php nouvelle.php (1.2 KB, 13 views)
Reply With Quote
The Following User Says Thank You to open For This Useful Post:
MaVerick88 (18th February 2014)
Reply

Tags
news , plugin

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



All times are GMT +2. The time now is 01:06. vBulletin skin by ForumMonkeys. Powered by vBulletin® Version 3.8.11 Beta 3
Copyright ©2000 - 2024, vBulletin Solutions Inc.