Joomla Tags - Overcome conflict with JPromoter Mambot

Overcome conflict with JPromoter Mambot Overcome conflict with JPromoter Mambot

  • Currently 4/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

We are aware of a conflict that happens with the bfFramework and JPromoter Mambot.

This is caused because both want to start the PHP Session for administrator. Now this could be argued that this is our problem or theirs as our framework calls system mambots on the admin side which is not a "normal" feature of Joomla (We always push the boundries!!) - and it could be a JPromoter issue because they blindly start a PHP session without regard for other components, namespaces or the fact that by loading system mambots in admin, their code has been run in admin when it never was intended/required.

The fix is simple.

In our framework we define a constant, and you will need to make a small change to the /mambots/system/jp.metaedit.php file to ensure their code is not run when it is not needed.

The change is to wrap the following code:

@session_start();
$_MAMBOTS->registerFunction( 'jpMetaEdit', 'jpmetaedit' );
global $mosConfig_absolute_path, $mosConfig_live_site;
require_once( $mosConfig_absolute_path.'/administrator/components/com_jp/joomlaequipment.config.php');
$_SESSION['REQ_URI'] = $_SERVER['REQUEST_URI'];

 

with a check - like this:

 

if (!defined('__BFADMINENTRY__')){
@session_start();
$_MAMBOTS->registerFunction( 'jpMetaEdit', 'jpmetaedit' );
global $mosConfig_absolute_path, $mosConfig_live_site;
require_once( $mosConfig_absolute_path.'/administrator/components/com_jp/joomlaequipment.config.php');
$_SESSION['REQ_URI'] = $_SERVER['REQUEST_URI'];
}

 

This will ensure that the jp.metaedit.php file doesnt corrupt the admin session when used through bfFramework

Article is in the following categories:
KB » How Do I - Questions Answered



Leave A Comment

or close

Email This Article

or close

Existing Comments

There are currently no comments.

Attachments Attachments

There are currently no files.

myNotes My Notes

You currently have no notes on this article. You can leave your own note on this page, the note can only be seen by you (and our administrators) but not other users.

You need to login first

Overcome conflict with JPromoter Mambot Article Information

Hits:
636
Created:
Thursday, 20 December 2007
Author:
Administrator
Last Modified:
Thursday, 20 December 2007
Access:
Public
Version:
2

Powered by Joomla Knowledgebase
Now Available For Joomla 1.5.x and Joomla 1.0.x!