Jump to content
DevFuse Forums
Michael

IP.Board Portal development

Recommended Posts

A template edit would be great if you could PM me it please?

 

It may also be an idea to add an option to the standard template, one of the problems with the portal is when someone puts a long post!!

 

PM Sent. The truncate function doesn't work for everyone but once I do find a good solution, plan on adding it.

 

 

I have a quick question about the portal, something I think worked in 1.3 or something way back, making www.example.org show the portal when the ip.board software is located in www.example.com/forum/, is this still possible, if not, could you make it possible in the future? :)

 

To be honest I haven't checked yet. I believe it's possible with IP.Content so will have a check when I get a chance to see if instructions/files can be included for the Portal.

Share this post


Link to post
Share on other sites

hi

 

i need a step by step tutorial how to setup portal like this please some one guide me

 

the portal should like this

 

http://www.devfuse.com/forums/portal/

 

 

and also member should visit portal first and then forum page

 

some guide me waiting for your replies

Share this post


Link to post
Share on other sites

hi

 

i need a step by step tutorial how to setup portal like this please some one guide me

 

the portal should like this

 

http://www.devfuse.com/forums/portal/

 

 

and also member should visit portal first and then forum page

 

some guide me waiting for your replies

 

 

Have to admit I'm in much the same boat (Although I do realize paid mods come first :thumbsup: )

Share this post


Link to post
Share on other sites

Go to initdata.php in the root of your forum and open it, find this line around line 50

 

define( 'IPS_DEFAULT_PUBLIC_APP', 'forums' );

 

And change it to

 

define( 'IPS_DEFAULT_PUBLIC_APP', 'portal' );

 

Your board will always open with portal first, good luck.

Share this post


Link to post
Share on other sites

Hi,

 

I have my portal on http://www.scenario-paintball.com and my forums on http://forums.scenario-paintball.com

 

My www virtual host has this option :

        DirectoryIndex portal.php

 

And this is my portal.php :

<?php
/**
* <pre>
* Invision Power Services
* IP.Board v3.2.0
* Main public executable wrapper.
* Set-up and load module to run
* Last Updated: $Date: 2011-03-11 12:41:48 -0500 (Fri, 11 Mar 2011) $
* </pre>
*
* @author      $Author: ips_terabyte $
* @copyright   (c) 2001 - 2009 Invision Power Services, Inc.
* @license     http://www.invisionpower.com/community/board/license.html
* @package     IP.Board
* @link        http://www.invisionpower.com
* @version     $Rev: 8042 $
*
*/

define( 'IPB_THIS_SCRIPT', 'public' );

/* Portal */
define( 'IPS_DEFAULT_PUBLIC_APP', 'portal' );
define( 'IPS_PUBLIC_SCRIPT', 'index.php' );
define( 'IPB_URL', 'http://forums.scenario-paintball.com' );

require_once( './initdata.php' );/*noLibHook*/

require_once( IPS_ROOT_PATH . 'sources/base/ipsRegistry.php' );/*noLibHook*/
require_once( IPS_ROOT_PATH . 'sources/base/ipsController.php' );/*noLibHook*/

ipsController::run();

exit();

?>

 

My problem is that www redirect to forums.

 

Any idea ?

Share this post


Link to post
Share on other sites

Problem solved. It's provide to the _fUrlComplete function of the ipsRegistry class :

        /* www.hostname.com vs hostname.com - need to ensure we are at the correct URL for AJAX purposes */
       if( !defined('CCS_GATEWAY_CALLED') && ipsRegistry::$request['request_method'] == 'get' )
       {
           $_requestedHost        = $_SERVER['HTTP_HOST'];
           $_configuredHost    = parse_url( ipsRegistry::$settings['board_url'], PHP_URL_HOST );
           $uri                = $_SERVER['REQUEST_URI']  ? $_SERVER['REQUEST_URI']  : @getenv('REQUEST_URI');
           $_t                    = !empty(ipsRegistry::$settings['board_url']) ? @parse_url( ipsRegistry::$settings['board_url'] ) : @parse_url( ipsRegistry::$settings['base_url'] );
           $_toTest            = ( $_t['path'] AND $_t['path'] != '/' ) ? preg_replace( "#^{$_t['path']}#", '', $uri ) : str_replace( $_t['scheme'] . '://' . $_t['host'], '', $uri );

           if( strpos( $_configuredHost, 'www.' ) === 0 AND strpos( $_requestedHost, 'www.' ) !== 0 )
           {
               ipsRegistry::getClass('output')->silentRedirect( ipsRegistry::$settings['board_url'] . $_toTest );
           }
           else if( strpos( $_configuredHost, 'www.' ) !== 0 AND strpos( $_requestedHost, 'www.' ) === 0 )
           {
               ipsRegistry::getClass('output')->silentRedirect( ipsRegistry::$settings['board_url'] . $_toTest );
           }
       }

Just add define ('CCS_GATEWAY_CALLED', false); in your portal.php.

 

I have a another problem. portal don't work if I rename admin folder...

Share this post


Link to post
Share on other sites

This announcement seems to be turning into a support topic, currently I'm only offering support for the Portal on the IPS Forums. You can find the support topic here. I've also created a suggestions topic for the next version here. Any bugs you encounter can be reported here.

 

To answer your question llaumgui, currently the Portal doesn't come with this file but I will be looking into it next version. I'll close this topic to prevent future confusion, the links above should cover everything.

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.

×