Quote
dayzign wrote:
Hi guys, i got situation here...
my front page has 3 columns page (default php-fusion interface), so how is it possible if i want to make it only 2 columns (let say left panel and center panel, no right panel), just right after i click on any news link in the first page (which is has 3 columns).... is there something to do with panel restriction? (exclude or include).....
Thx in advance.....
Quote
Fangree_Craig wrote:
Hi there,
Go and install FP News Panel...
http://www.php-fusion.co.uk/infusions/addondb/view.php?addon_id=352
Then read this....
http://www.php-fusion.co.uk/forum/viewthread.php?forum_id=85&thread_id=29584&pid=162956#post_162956
That should help you out.
Also Admin >>> Settings >>> Main if you want to exclude right panels on news.php just enter /news.php in the textbox and save.
Good Luck!
Quote
dayzign wrote:
just right after i click on any news link in the first page (which is has 3 columns)...
Quote
If you do not find a solution within the administrative panel interface, you can make a small modification in the file: \includes\theme_functions_include.php
find a function called "check_panel_status", and make a change from line 44.
[syntaxhighlighter brush=php,first-line=1,highlight=0,collapse=false,html-script=false]
if (is_array($exclude_list)) {
if ( (isset($_GET['readmore'])) && (isnum($_GET['readmore'])) ) {
if ($side == "right") { return false; }
} else {
$script_url = explode("/", $_SERVER['PHP_SELF']);
$url_count = count($script_url);
$base_url_count = substr_count(BASEDIR, "/")+1;
$match_url = "";
while ($base_url_count != 0) {
$current = $url_count - $base_url_count;
$match_url .= "/".$script_url[$current];
$base_url_count--;
}
if (!in_array($match_url, $exclude_list) && !in_array($match_url.(FUSION_QUERY ? "?".FUSION_QUERY : ""), $exclude_list)) {
return true;
} else {
return false;
}
}
} else {
return true;
}
[/syntaxhighlighter]
PS. Remember to change the parameter "right" to the side you want to delete. :)
-
if ($side == "right") { return false; }
Quote
dayzign wrote:
Hello halisson, i already made change from the script you gave, but the next page still shows 3 columns after click.... did i miss something here?, isnt it?Code Download sourceif ($side == "right") { return false; }
Quote
dayzign want the three columns on the first page ("news.php",
but when any news is read ("?readmore", the left or right is automatically hidden.
Quote
If there is any news reading (a url with a parameter called "?readmore" all panels that are specified on the side (right or left) will be hidden.
.../news.php -> Without MOD. All sides are displayed normally (of course, the panels are hidden, if they are configured as hidden in admin panel).
.../news.php?readmore=... -> The MOD works by making a reading of $ _GET. If there is the "readmore", it returns "false", and hides all the specified side panels.
The changed file is attached. Replace the original file. Good Luck.
-
Quote
Ankur wrote:
Please don't make it complicated :x
Why don't you simply Add the Site Opening Page (e.g /news.php) into Admin Panel --> Settings --> Main --> Exclude Right Panels ! Simple ! :G
Quote
dayzign wrote:
@Hallison : still show 3 columns after click, mate, maybe because a lot of changes i made on the code, but at least you showed me which part of the code that i have to handle with, thanks anyway...
Quote
halisson wrote:
Ankur, If you do not understand the question, the feature of the administrative panel is not enough to solve. But if you really be saying that the request for aid from dayzign is invalid, then not get me wrong, you have worked hard for the growth of PHPFUSION, but if the PHPFUSION is a project of open source, this implies one of the reasons for their existence: The possibility of change. And that's one thing That has to be done democratically.
-
Quote
Ankur wrote:
But IMO, the Code :
[syntaxhighlighter brush=php,first-line=1,highlight=0,collapse=false,html-script=false]if (!in_array($match_url, $exclude_list) && !in_array($match_url.(FUSION_QUERY ? "?".FUSION_QUERY : ""), $exclude_list)) {
return true;
} else {
return false;
}[/syntaxhighlighter]
works for both /news.php and /news.php?readmore=1. Tested !
Quote
halisson wrote:
This seems to be a good alternative. :)
But specifically to the page of the news, I think that is not the solution.
If I understand your code, any url that contain parameters, the system will hide one side,
no matter if it is a page of news, am I right?
-
Quote
Fangree_Craig wrote:
Stick ankurs code in a upper center panel and enable for /news.php only then it will only do as it on news.php like you want.
Quote
Fangree_Craig wrote:
I understand fully what he wants to do thanks. My first language is English. :)
Quote
Fangree_Craig wrote:
NO, I am not joking I fully understand what the guy is trying to do. Why would I joke about that?
You have too much to say, tone it down a bit. ;)
Category Forum
System Administration - 8Labels
None yet
Statistics
4 participants
Notifications
You are not receiving notifications from this thread.
Related Questions