Page 1 of 1

Enable and Disable the Portal

Posted: 4. January 2009 21:21
by cap0ne
Your Portal Version: 1.0.0RC3
Your phpBB Type: Standard phpBB3
MODs installed: No
Your knowledge: Beginner

PHP Version: 4.4.4-8
MySQL Version: 5.0.32

What have you done before the problem was there?
Modified:
includes/acp/acp_portal.php
Added: 'portal_enable' => array('lang' => 'PORTAL_ENABLE' , 'validate' => 'bool' , 'type' => 'radio:yes_no' , 'explain' => true),
Modified:
language/en/mods/lang_portal_acp.php
Added: 'PORTAL_ENABLE' => 'Enable Forum',
'PORTAL_ENABLE_EXPLAIN' => 'This allows you to turn on and off the portal feature',

Added: phpbb_portal_config (config_name, config_value) VALUES ('portal_enable', '1'); to the sql


What have you already tryed to solve the problem?


Description and Message
I'm looking for a function that will allow me to turn the portal on and off within the ACP. As you can see above I have already
added the cosmetic fields however I need the function to make it work.

Function Logic:
If portal_enable = 1 then portal.php = index.php
if portal_enable = 0 then index.php = index.php

I'm not sure if I need to modify the includes/functions.php and /index.php or if adding the function to a portal file would work better.

Thanks
Al

Re: Enable and Disable the Portal

Posted: 5. January 2009 12:49
by Kevin
This should be it:
http://board3deportal.svn.sourceforge.n ... vision=394

Included in the next version.