Custom Panels Control v1.00 RC1
PHP-Fusion: v7.00.x
author: WEC
email: wechallenge::lycos.co.uk
last modified: 2008-08-20
----------------------------------------------------
Released under the terms and conditions of the
GNU Affero General Public License (AGPL) (Version 3)
----------------------------------------------------

DESCRIPTION
-----------
This MOD/Infusion is based on core v.7.00 files '\administration\panel_editor.php' and '\themes\templates\panels.php' where code has been added in order to be able to restrict panel display to a single or more PHP-Fusion page only.

MOD is latest tested on v.7.00.

It's a modification of Fusion core files, so back up your installation and database before installing this MOD. 

Features include:

. Option to restrict panel display to a single page, more pages or the default PHP-Fusion all pages.
. Option to define the listed urls as exclud or include list.



INSTALLATION
------------
1. Upload the content of the files folder. This will replace your existing files '\administration\panel_editor.php' and '\themes\templates\panels.php' with the files supplied by this MOD.


2. Go to System Admin, Infusions and infuse the Custom Panels Control.


3. Manage panels via the usual Panels management in the PHP-Fusion System Admin.


4. In the Panels management enter the urls where you wish to restrict the panel to be displayed on like:

/forum/index.php
/news.php
/downloads.php

By default the MOD will enterpret the listed urls as an exclude list and not display panels on the listed urls. You  have the option to define the listed urls as an include list.

For left and right side panels this is straight forward, but if you wish to restrict upper and lower center panels, then you must pick the normal "Display panel on all pages".


UNINSTALLATION
--------------
1. Go to System Admin, Infusions and defuse the Custom Panels Control.

2. Replace your files '\administration\panel_editor.php' and '\themes\templates\panels.php' with original files.

3. Delete the folder '\infusions\custom-panels_control'.


CREDITS
-------
'\administration\panel_editor.php' and '\themes\templates\panels.php' have been modified from the Fusion core files.


CHANGELOG
---------

Version 1.00 RC1
----------------

. Removed block control since similar funtionality has been introduced in core v7.00
. W3C XHTML 1.0 Transitional
. Code rewritten for PHP-Fusion 7.00

Version 0.28
------------
. Added unset($defuse); to administration\infusion.php in order to prevent unintentional defusing of custom fields

Version 0.27
------------
. Workaround for the cleanurl() introduced in 6.0.1.11 core for server globals

Version 0.26
------------
. Added error message in \administration\panel_editor.php in case U-Ctr or L-Ctr panel is restricted by url, but not set to be displayed on all pages 

Version 0.25
------------
. Fixed path bug in \infusions\custom-panels_control\block_admin.php, which made the block control fail when PHP-Fusion was installed in a subfolder

Version 0.24
------------
. Renamed infusion folder from custom_panels_control into custom-panels_control since the **_panel** in folder name caused the infusion to be listed as a panel in Panels Admin

Version 0.23
------------
. Fixed error notice

Version 0.22
------------
. Changed varchar (100) to TEXT in infusion.php 

Version 0.21
------------
. Added manual editing description

Version 0.20
------------
. Added admin page for display of side_left, U-Ctr, L-Ctr and side_right blocks

Version 0.14
------------
. Made option to enterpret url list as a blacklist instead of the default as a whitelist 

Version 0.13
------------
. Made checkbox option to use extended url. Unticked use $_SERVER['PHP_SELF'], ticked use $_SERVER['REQUEST_URI'] to check if panel should be displayed

Version 0.12
------------
. Made option to enter more urls for the panel display

Version 0.11
------------
. Removed beginning / from url entry box to follow usual PHP-Fusion format
. Fixed display of panel url in preview mode
. Fixed error Notice

Version 0.10
------------
. Basic MOD to get the idea going.


TODO
----
Add more locale files


=======================================================================================================
MANUAL EDITING OF CORE FILES IF YOU PREFER TO EDIT FILES YOURSELF E.G. FOR LATER RELEASES OF PHP-FUSION
=======================================================================================================

See the following htm files for manual editing description:

- administration_panel_editor.php_diff.htm
- themes_templates_panels.php_diff.htm

