|
FP News Panel
|
| Craig |
Posted on 12-07-2011 19:55
|

Fusioneer

Posts: 3980
Joined: 27/09/2005
|
FP News Panel gives the option to display news in double columns.
-- View this Addon -- |
| |
|
|
| jikaka |
Posted on 12-07-2011 19:55
|

Admin

Posts: 743
Joined: 28/01/2010
|
very very nice!
good man!
|
| |
|
|
| HaYaLeT |
Posted on 12-07-2011 21:10
|

Senior Member

Posts: 276
Joined: 31/10/2008
|
Awesome! can you put maximum summary character code?
Live Demo: http://www.design...m/news.php
example code: Code $news_news = $data['news_breaks'] == "y" ? nl2br(stripslashes(substr($data['news_news'],0,100))) : stripslashes(substr($data['news_news'],0,100));
because summary of the different then one of the following is one of the above be.
Edited by HaYaLeT on 12-07-2011 21:52
|
| |
|
|
| Craig |
Posted on 12-07-2011 23:51
|

Fusioneer

Posts: 3980
Joined: 27/09/2005
|
You have put that is no problem but I will not change it in this panel as it's not needed.
|
| |
|
|
| HaYaLeT |
Posted on 13-07-2011 00:39
|

Senior Member

Posts: 276
Joined: 31/10/2008
|
i understand,added turkish support site.. |
| |
|
|
| Craig |
Posted on 13-07-2011 00:43
|

Fusioneer

Posts: 3980
Joined: 27/09/2005
|
Oh! You are a moderator on the Turkish Support Site yes. Nice. I did not realise that. 
OK nice thank you.
|
| |
|
|
| Kevin Maschke |
Posted on 13-07-2011 00:55
|

Member

Posts: 165
Joined: 11/12/2006
|
OK SORRY.
SOLVED.
I did not follow all the instructions for 2 column news panel.
Now it works!
Can delete thread!
<3 PHP-Fusion
|
| |
|
|
| Craig |
Posted on 13-07-2011 00:55
|

Fusioneer

Posts: 3980
Joined: 27/09/2005
|
All good now?
|
| |
|
|
| Ankur |
Posted on 13-07-2011 05:47
|

Admin

Posts: 1291
Joined: 02/11/2010
|
Well Done Craig... 
You did it...
|
| |
|
|
| Craig |
Posted on 16-07-2011 22:05
|

Fusioneer

Posts: 3980
Joined: 27/09/2005
|
FP News Panel For BB Codes for Articles & News Mod
If anyone is using our [BB Codes for Articles & News] Mod and you need it to work with FP News Panel replace fp_news_panel with this one....
Code<?php
/*-------------------------------------------------------+
| PHP-Fusion Content Management System
| Copyright © 2002 - 2011 Nick Jones
| http://www.php-fu...
+--------------------------------------------------------+
| Type: Panel
| Name: FP News Panel
| Version: 1.00
| File Name: fp_news_panel.php
| Author: Fangree Productions
| Site: http://www.fangre...
| Contact:
| Developers: Fangree_Craig
| Additional code from PHP-Fusion V7.02 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/licen... Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
if (!defined("IN_FUSION")) { die("Access Denied"); }
include LOCALE.LOCALESET."news_cats.php";
// BB Codes For Articles Mod
if ((file_exists(INCLUDES."na_bbcodes_settings.php"))) {
require_once INCLUDES."na_bbcodes_settings.php";
}
if ($bbcodes =="1") {
require_once INCLUDES."bbcode_include.php";
}
///
//////////SETTINGS/////////////////////////////////////////////
//Single or double column news 1 == Single || 0 == Double collumn
$single = 0;
// Number of news displayed
$items_per_page = 4;
// Counter for Displaying News in 2 Columns NO NEED TO CHANGE THIS.
$counter = 3;
/////////////SETTINGS END /////////////////////////////////////
$i = 0;
if (!isset($_GET['readmore']) || !isnum($_GET['readmore'])) {
$rows = dbcount("(news_id)", DB_NEWS, groupaccess('news_visibility')."
AND (news_start='0'||news_start<=".time().")
AND (news_end='0'||news_end>=".time().")
AND news_draft='0'");
if (!isset($_GET['rowstart']) || !isnum($_GET['rowstart'])) { $_GET['rowstart'] = 0; }
if ($rows) {
$result = dbquery(
"SELECT tn.*, tc.*, tu.user_id, tu.user_name, tu.user_status, news_news
FROM ".DB_NEWS." tn
LEFT JOIN ".DB_USERS." tu ON tn.news_name=tu.user_id
LEFT JOIN ".DB_NEWS_CATS." tc ON tn.news_cat=tc.news_cat_id
WHERE ".groupaccess('news_visibility')." AND (news_start='0'||news_start<=".time().")
AND (news_end='0'||news_end>=".time().") AND news_draft='0'
GROUP BY news_id
ORDER BY news_sticky DESC, news_datestamp DESC LIMIT ".$_GET['rowstart'].",".$items_per_page
);
$numrows = dbrows($result);
if ($single !=="1") {
echo "<table valign='top' cellpadding='0' cellspacing='2' width='100%' border='0'>\n<tr>\n";
}
while ($data = dbarray($result)) {
$i++;
$comments = dbcount("(comment_id)", DB_COMMENTS." WHERE comment_type='N' AND comment_hidden='0' AND comment_item_id='".$data['news_id']."'");
$news_cat_image = "";
$news_subject = "<a name='news_".$data['news_id']."' id='news_".$data['news_id']."'></a>".stripslashes($data['news_subject']);
$news_cat_image = "<a href='".($settings['news_image_link'] == 0 ? "news_cats.php?cat_id=".$data['news_cat'] : BASEDIR."news.php?readmore=".$data['news_id'] )."'>";
if ($data['news_image_t2'] && $settings['news_image_frontpage'] == 0) {
$news_cat_image .= "<img src='".IMAGES_N_T.$data['news_image_t2']."' alt='".$data['news_subject']."' class='news-category' /></a>";
} elseif ($data['news_cat_image']) {
$news_cat_image .= "<img src='".get_image("nc_".$data['news_cat_name'])."' alt='".$data['news_cat_name']."' class='news-category' /></a>";
} else {
$news_cat_image = "";
}
// BB Codes For News Mod
if($bbcodes == 1) {
$news_news = $data['news_breaks'] == "y" ? "y" : "n" ? nl2br(stripslashes(parseubb(parsesmileys($data['news_news'])))) : stripslashes($data['news_news']);
}else{
$news_news = $data['news_breaks'] == "y" ? nl2br(stripslashes($data['news_news'])) : stripslashes($data['news_news']);
}
///
$news_info = array(
"news_id" => $data['news_id'], "user_id" => $data['user_id'],
"user_name" => $data['user_name'], "user_status" => $data['user_status'],
"news_date" => $data['news_datestamp'], "cat_id" => $data['news_cat'],
"news_news" => $data['news_news'], "cat_name" => $data['news_cat_name'],
"cat_image" => $news_cat_image, "news_subject" => $data['news_subject'],
"news_ext" => $data['news_extended'] ? "y" : "n", "news_reads" => $data['news_reads'],
"news_comments" => $comments, "news_allow_comments" => $data['news_allow_comments'],
"news_sticky" => $data['news_sticky']
);
if ($single =="1") {
echo "<!--news_prepost_".$i."-->\n";
render_news($news_subject, $news_news, $news_info);
}else{
echo "<td style='vertical-align: top; width: 50%;'>\n";
echo "<!--news_prepost_".$i."-->\n";
render_news($news_subject, $news_news, $news_info);
echo "</td>\n";
if ($counter % 2 == 0){ echo "</tr>\n<tr>\n"; }
$counter++;
}
}
if ($single !=="1") {
echo "</tr>\n</table>";
}
echo "<!--sub_news_idx-->\n";
if ($rows > $items_per_page) echo "<div style='margin-top:5px; text-align: center;'>\n".makepagenav($_GET['rowstart'],$items_per_page,$rows,3)."\n</div><br />\n";
} else {
opentable($locale['global_077']);
echo "<div style='text-align: center;'><br />\n".$locale['global_078']."<br /><br />\n</div>\n";
closetable();
}
}
?>
|
| |
|
|
| mNm |
Posted on 21-12-2011 20:17
|

Newbie

Posts: 5
Joined: 27/07/2010
|
I have some problems with pagination. When i do next page the infusion is not showing other page content.. URL is home.php?rowstart=2 and there is nothing to show. How to solve problem?
C-S.LT Gaming Community :: MasterServers - working on!
|
| |
|
|
| Craig |
Posted on 21-12-2011 20:20
|

Fusioneer

Posts: 3980
Joined: 27/09/2005
|
PHP-Fusion V7.02.04 Panels bug not a bug with this panel.
Fix is here...
http://next.php-f...post_22777
|
| |
|
|
| mNm |
Posted on 21-12-2011 20:30
|

Newbie

Posts: 5
Joined: 27/07/2010
|
thx. but just i myself make a solution. just copyed panel code content to news.php
C-S.LT Gaming Community :: MasterServers - working on!
|
| |
|
|
| roslensaub |
Posted on 17-04-2012 02:39
|

Newbie

Posts: 3
Joined: 17/04/2012
|
mNm wrote:
thx. but just i myself make a solution. just copyed panel code content to news.php 
i a new user of pfp fusion. i have this problem too. what do u mean by copy panel code? all the code in fp_news_panel.php to news.php? or replace all the code to news.php? plz help me. thanks |
| |
|
|
| Craig |
Posted on 01-06-2012 12:41
|

Fusioneer

Posts: 3980
Joined: 27/09/2005
|
If you read in the readme I am pretty sure it explains it all there, failing that head to http://www.fangre... forums where you will find FP News panel support thread there you might also find the solution.
This Addons is no longer supported here.
Thanks
|
| |
|
|
| zodan |
Posted on 18-12-2012 18:23
|

Junior Member

Posts: 44
Joined: 24/10/2011
|
Hello everyone and thank you for what you do, I installed this infusion with the change to the news and articles, but I noticed that these panels are always at the top, in the sense that for example, if a user wants to register, the panel for recording remains in the bottom of the page after the news (like all the other panels that may need to appear in place of the news es.videogallery etc etc) on my site are always visible. I hope I explained, there's a solution.
My site: HERE |
| |
|
|
| Craig |
Posted on 18-12-2012 18:31
|

Fusioneer

Posts: 3980
Joined: 27/09/2005
|
Read the Reame it states in there what to do. Include it to display on your home.php only.
|
| |
|
|
| smokeman |
Posted on 18-12-2012 18:38
|

Veteran Member

Posts: 960
Joined: 23/06/2006
|
Yes and a lot of popup's advertises and exploits too.. 
|
| |
|
|
| Craig |
Posted on 18-12-2012 18:41
|

Fusioneer

Posts: 3980
Joined: 27/09/2005
|
I did warn richard about this site already. Anyway it's not our problem.
|
| |
|
|
| zodan |
Posted on 18-12-2012 18:55
|

Junior Member

Posts: 44
Joined: 24/10/2011
|
Oh my god I delete everything! I've posted just today but they take off |
| |
|