Instructions for v3.19a of the Bridge: (for use with SMF 1.0.x and SMF 1.1RC1 or prior)
For SMF1.1 RC2, please use the bridge v1.1.1 (aka 3.20) and see the instructions higher in this thread.It should be noted, before you start with this bridge...
Everything in these instructions assumes that you already have Mambo (4.5.1 or 4.5.2) or Joomla v1.0.5 or prior installed
and SMF (1.0.1, 1.0.2, 1.0.3, 1.0.4, or 1.0.5) (and 1.1 beta3, 1.1 beta 4 is now supported with a separate version of Orstio's Bridge) installed and both are working as stand-alone utilities.
NOTE: Mambo 4.5.3 changes things! v3.19a of the bridge is not intended to work with the 4.5.3For simplicity, if you don't know exactly what you are doing:
- SMF should be installed in a "top level" directory. (i.e.
www.yoursite.com/forum or
something like that)
- Mambo can be installed in a "top level" directory or at the top level itself.
to get the bridge, go to:
http://mamboforge.net/frs/?group_id=543START:
First, unzip the Bridge ZIP file
This will extract to create a number of subdirectories and files.
step-by-step install
misc modules
mosbot
It should be noted that these instructions assume that you have never had the bridge
installed before. If you have had the bridge previously installed, some steps may
already have been done, or may fail with the automatic installs, since the code they
are looking to modfy has already been modified. For upgrade details, I have made a
separate section of these instructions.
INSTALLATION INSTRUCTIONS:
Now that you have all the files unzipped and ready to load, you can log in to your
server and start installation.
This README has a detailed instructions, but the new step-by-step design makes things
fairly easy and straight-forward. Make sure you read all the README files in each of
the directories.
1) Install the package in SMF.
1a) Using your (standalone) SMF, go to the package manager
1b) Choose Download a new Package
1c) From the the "step-by-step install/step 1" directory, upload
"smf_mambo3.1.tar.gz" and apply the mod.
2) Install the Simple Machines Forum component.
2a) Using Mambo Admin > Components > Install/Uninstall Component
2b) Choose Upload File Package and Browse to the "step-by-step install/step 2"
directory and choose the file called "com_smf.zip"
3) Install the Simple Machine Forum Registration component.
3a) Using Mambo Admin > Components > Install/Uninstall Component
3b) Choose Upload File Package and Browse to the "step-by-step install/step 3"
directory and choose the file called "com_smf_registration.zip"
This uses the registration options in your Mambo Admin > Global Configuration,
just like the Mambo default registration.
4) Install the smf_login Module.
4a) Using Mambo Admin > Modules > Install/Uninstall Module
4b) Choose Upload File Package and Browse to the "step-by-step install/step 4"
directory and choose the file called "mod_smf_login.zip"
5) Modify the index.php of your Mambo Template.
5a) Go to directory MAMBO/templates/NAME (where MAMBO is your mambo directory and
NAME is the name of the template.)
5b) Open index.php
5c) Add the following code just before the </HEAD> tag in index.php
<?php
global $sc, $context;
if (!defined('SMF')){
require ("administrator/components/com_smf/config.smf.php");
require ($smf_path."/SSI.php");
}
$sc = &$context['session_id'];
$_SESSION['USER_AGENT'] = $_SERVER['HTTP_USER_AGENT'];
mysql_select_db($mosConfig_db);
?>
AND add the following just above the </body> tag:
<?php mysql_select_db($db_name); ?>
6) Configure the SMF component in Mambo Admin.
6a) Using the Mambo Admin, choose Components> Simple Machines Forum > Edit Config
6b) Set the Path to SMF. This is NOT a URL! This is the absolute path to your SMF
Installation.
(Usually this will be something similar to /home/username/public_html/forum)
6c) Choose if you want your Forum wrapped or unwrapped.
It should be noted that there are essentially three formats to display your
Mambo/Forum integration:
Wrapped: You are using SMF through the Mambo bridge. The Forum appears
"wrapped" in the Mambo tables.
Unwrapped: You are still using SMF through Mambo, but it doesn't have the
look of a wrapped forum. It looks stand-alone, but it is actually
loading through Mambo.
This is set in the Mambo config for the component.
(The changes to MOS_SMF.php are not required in this case.)
Stand-alone: You don't want your forum URL to change.
This would be if you already have a large SMF userbase, and you
don't want them to have to change the URL that they probably have
bookmarked. In that case, make the changes in MOS_SMF.php as noted.
7d) Choose if you want to use the bridge registration or the standard SMF registration.
The bridge registration looks like mambo's registration method...
but both options will still result in the users being added to both databases (eventually).
7 ) Other Configuration notes
7a) You will probably want to start SMF off with default settings...
7b) If you make the Mambo menu item (for the SMF component) available to registered
users only, the login and registration may not function correctly.
7c) Activation emails should be handled by Mambo.

in Mambo Admin > Modules > Site Modules: Unpublish the (default Mambo) mod_login module.
9) in Mambo Admin > Modules > Site Modules: Edit the mod_smf_login module.
It is a known issue in Mambo that modules must be "saved" at least once in order to
be fully activated.
10a) Choose what options you want displayed in your Login box...
10) In Mambo Admin > Menu > User Menu Remove the link for the User Profile.
(You will not want Mambo to handle the user information any more)
11) In Mambo Admin > Site > Trash Manager: Click on the Menu Items tab and delete all
the trashed items... (this cleans up the ItemID stuff. If you ever uninstall your smf
bridge, you will want to delete the old menu item and remove the trash before adding
a new version of the bridge. Otherwise Mambo may get confused as to which ItemID the
real bridge is using.)
THEMING:
Changing the SMF doc_type from xhtml to html will handle many of the basic "super
large font" issues.
The can be done by changing the line near the top of index.template.php in your SMF
Theme directory.
However, some of the Mambo templates and SMF themes do not play well together.
In the Mambo Template, fixed width templates of less than 500 pixels width are
difficult for SMF to "fit in".
You have two main options.
The first is to increase the basic width of the Mambo Template.
-> In MAMBO/templates/TEMPLATE_NAME/index.php, change the width call of the main
table to something larger...
The second option, which may require some tweaking, is the change the Mambo Template
into a variable width template.
-> In MAMBO/templates/TEMPLATE_NAME/index.php, change the width call of the main
table 100%...
In addition to the width issues, there are some overlaps in the CSS entires between
Mambo and SMF.
The CSS files for Mambo and SMF have some duplicate values that may conflict.
A proper design of the bridged site will include personalized templates/themes for
Mambo and SMF that
will avoid this situation. This may take some time (and effort), however. You can
make a "quick and dirty"
merge of the CSS files by doing the following:
Open the MAMBO/templates/TEMPLATE_NAME/css/template_css.css file
Open the SMF/Themes/THEME_NAME/style.css file
Copy all of the SMF Theme file into the Mambo template file.
Remove the Duplicate entries from the newly copied portion.
(In other words, if the CSS entry exists in the Mambo template, delete the entry in
the newly created SMF section)
Now save it, and then remove the same "duplicate" entries in the style.css file in
your SMF theme directory.
FIXING LINKS IN SMF MESSAGES FROM PRE-BRIDGED FORUMS
(thanks to goosemoose for this)
If you were running a forum prior to bridging it with mambo, there will be links in
messages that point to the unbridged forum location. You can change these by going
into phpMyAdmin and running a simple SQL command on the smf_messages table.
The format is:
UPDATE smf_messages SET `body` = replace(`body`,"http://www.yoursite.com/forum/index.php?topic=","http://www.yoursite.com/mambo/index.php?option=com_smf&Itemid=##&topic=")
where smf_messages is your actual table (change the smf_ if you are using a different
prefix, obviously)
where
http://www.yoursite.com/forum/index.php is the actual URL of your previous
(unbridged) SMF index.php.
where
http://www.yoursite.com/mambo/index.php is the actual loationof your MAMBO
index.php
where Itemid=## is your actual SMF component Itemid
so, an example, (as provided by goosemoose)
UPDATE rfc_messages SET `body` = replace(`body`,"http://www.goosemoose.com/rfc/index.php?topic=","http://www.goosemoose.com/index.php?option=com_smf&Itemid=70&topic=")
He used rfc_ as his SMF database table prefix and rfc was the SMF directory.
note that his mambo is installed in the root directory...
USING THE BRDIGE WITH NO GUEST ACCESS TO YOUR FORUM
To get the best functionality, you should have your forum available to guests (one section is all that is required).
If, for some reason, you feel that guest viewing of your forum should not be allowed, at all, then you can try the following fix.
In SMF's index.php, find the guest access "whitelist" (things guests are allowed to do) and add mambo_login, as suggested below.
// If guest access is off, a guest can only do one of the very few following actions.
elseif (empty($modSettings['allow_guestAccess']) && $user_info['is_guest'] && (!isset($_REQUEST['action']) || !in_array($_REQUEST['action'], array('login', 'login2', 'mambo_login', 'register', 'register2', 'reminder', 'activate', 'help', '.xml'))))
UPGRADING THE BRIDGE
If you are upgrading, and just want to over-write the files, the new version (3.1)
adds a number of files that did not exist pre-3.0.
These go into administrator/components/com_smf/:
admin.smf.php
config.smf.php
install.smf.php
smf.xml
toolbar.smf.html.php
toolbar.smf.php
uninstall.smf.php
These goes in components/com_smf/:
smf.php
the entire language/ directory and all files in it
These goes in administrator/components/com_smf_registration/:
admin.smf_registration.php
config.smf_registration.php
install.smf_registration.php
smf_registration.xml
toolbar.smf_registration.html.php
toolbar.smf_registration.php
uninstall.smf_registration.php
These goes into components/com_smf_registration/:
smf_registration.php
smf_registration.html.php
This goes into your SMF /Sources/:
MOS_SMF.php