• Welcome to Simple Machines Community Forum. Please login or sign up.
January 29, 2022, 12:57:26 AM

News:

SMF 2.1 RC4 has been released! Try it out and help us test! :) Read more.


Can someone try these on for size?

Started by [Unknown], January 01, 2005, 01:52:09 PM

Previous topic - Next topic

[Unknown]

January 01, 2005, 01:52:09 PM Last Edit: January 10, 2005, 01:37:48 AM by [Unknown]
I've made a few modifications to the SMF component, and I'd like to see what people think of them - especially Orstio, as I would say he's the most experienced with Mambo/SMF integration.

I've attached two components.  All the files in them have been modified, with the following changes:
  - the config file now *tries* to auto detect some settings.
  - the administration panel now supports backslashes (windows paths.)
  - the install process should look just ever so slightly nicer.
  - the bridge now doesn't query for the Itemid if it already has it.
  - session problems should happen less now.

I also have a second component.  This is essentially the same thing, with all the same changes, but it instead uses SMF's index.php instead of SSI.php - this should make mods easier to install, keep version numbers up, and solve theme problems.  But, this method does require some changes to files.  I've attached a package that should make those changes for you automatically.

The forum will still work with the package uninstalled, but it won't integrate properly.  If the forum is accessed directly, however, the package's changes will have no effect.

Please tell me if you have any problems, comments, suggestions, or thoughts.  And, Orstio, please tell me if I'm stepping on your toes at all.  I still consider this your project, and I'm just trying to help make it better ;).  If you want or don't want to use these files (or any of the changes I made to them), it's fine with me.

Edit: As a last note, I've only tested this with 4.5.1a.  I'm not sure it will work with older versions.

-[Unknown]

[Unknown]

Oh, and, almost forgot.  Wrote this up too:

How to install SMF 1.0 in Mambo:

Step 1. Go to your Mambo Administration panel.  Under the "Components" menu, select "Install/Uninstall".  In the section labelled "Upload Package File", upload the com_smf_1-0.zip file.

It should now be installed.  To check its settings, please go to Components and select Simple Machines Forum -> Edit Config.  Your settings may already have been detected, but it's still a good idea to verify them and save them.

Now go to the Menu Manager. Pick the menu you want SMF to appear on, and click "New" up near the top.  Pick Component, and make sure to publish it to the public.

-[Unknown]

Orstio

QuotePlease tell me if you have any problems, comments, suggestions, or thoughts.  And, Orstio, please tell me if I'm stepping on your toes at all.  I still consider this your project, and I'm just trying to help make it better .  If you want or don't want to use these files (or any of the changes I made to them), it's fine with me.

Not a problem at all.  I will test them out.  Thanks for looking at the code.  I definitely see improvements in your changes.   :)

QuoteI also have a second component.  This is essentially the same thing, with all the same changes, but it instead uses SMF's index.php instead of SSI.php - this should make mods easier to install, keep version numbers up, and solve theme problems.  But, this method does require some changes to files.  I've attached a package that should make those changes for you automatically.

This changes any matches to $scripturl to $myurl in the output buffer?  The last time I tried that, all attached images failed to load, because the PHP does not get executed in the output buffer.  Has this changed in 1.0?

I definitely like the changes to config.smf.php.  :)

[Unknown]

Quote from: Orstio on January 01, 2005, 03:06:41 PM
This changes any matches to $scripturl to $myurl in the output buffer?  The last time I tried that, all attached images failed to load, because the PHP does not get executed in the output buffer.  Has this changed in 1.0?

I had to mangle it a bit for xml, attachments, help popups, and the like to work.  That's part of what the package helps with... but, please do try it yourself and tell me how it works for you.  Often, such things are somewhat server and setting dependent.

I'm glad the changes to config.smf.php are good ;).

Thanks,
-[Unknown]

[Unknown]

Statistics weren't being counted properly.  Find in components/com_smf/smf.php:

template_header();
loadSubTemplate(isset($context['sub_template']) ? $context['sub_template'] : 'main');
template_footer();


Add after:


// Clear out the stat cache.
trackStats();


I'll update the packages a bit later.

-[Unknown]

Slack

Do we need to un-install the current bridge to try this version - or will this just over-write?

Thanks,
slack

[Unknown]

I think the old one needs to be uninstalled.  I don't know anything about upgrading components with Mambo... there's probably a way for it, but this component doesn't use it (I don't think it does, at least.)

-[Unknown]

Orstio

I've tried the version with the output buffer.

Attachments work.  ;)

But, all submission buttons (post, preview, vote, etc.) take the user back to the unwrapped forum.  :(

Slack

QuoteBut, all submission buttons (post, preview, vote, etc.) take the user back to the unwrapped forum.

I'll let you guys test it for awhile.   ;D

[Unknown]

Quote from: Orstio on January 01, 2005, 05:33:02 PM
But, all submission buttons (post, preview, vote, etc.) take the user back to the unwrapped forum.  :(

That means you didn't install the package.  It's intended to change the redirect URLs as well.

-[Unknown]

Orstio


[Unknown]

I'd like to note though, that I've done some things for 1.1 to make integration easier already ;).

-[Unknown]

hshan

January 08, 2005, 12:46:03 PM #12 Last Edit: January 09, 2005, 01:14:46 PM by hshan
I'm not quite clear on this.. and I'm willing to test it out.

The way I interpret it is:
  • com_smf_1-0.zip is a replacement for the regular com_smf. I need to uninstall com_smf first before installing unknown's adaptation.
  • com_smf_1-0_ob.zip is a bigger change and also needs com_smf (from the bridge installation) uninstalled, before installing it. Also, with this version, I need to install the mambo package in smf, which changes two files in my smf install.

Or do I have this all wrong? Do I need to completely remove the bridge before proceeding.. including the edited smf files ie. index.template.php, Login.template.php, BoardIndex.template.php (changed the login2 and logout to point to mod_smf_login) and the index.english.php edited file? What about the mos_smf.php file in /sources?.. is it still needed?

I tried using the com_smf_1-0.ob.zip component and installing the package, but the package when I was to install it, under "description" said parse error something. Then I manually edited the two files that the package was going to edit (backed them up first of course). When I clicked on my forum button in mambo (menu created from componant) an empty window opened up from within mambo. I've since uninstalled the componant and replaced the smf backup files, and installed the com_smf_1-0.zip component. I've changed all of the theme files back to their original state (it looked like com_smf_1-0.zip was referencing login2?) I have the smf login still published and the mambo login unpublished. I'm having an issue with a newly created user being seen on mambo, though I see it in myphp admin. I don't have duplicate mambo menu entries for my com_smf in myphp admin.

When I try to login via the mod_smf_login on mambo, with the newly created user, I receive these errors :


Notice: You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'AND g2.group_id='Registered'' at line 4 in /home/rngmkr/public_html/mbo/includes/database.php on line 184

Notice: You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'AND g2.group_id='Administrator'' at line 4 in /home/rngmkr/public_html/mbo/includes/database.php on line 184

Warning: Cannot modify header information - headers already sent by (output started at /home/rngmkr/public_html/mbo/includes/database.php:184) in /home/rngmkr/public_html/smf/Sources/Subs.php on line 1699

Warning: Cannot modify header information - headers already sent by (output started at /home/rngmkr/public_html/mbo/includes/database.php:184) in /home/rngmkr/public_html/smf/Sources/Subs.php on line 1700


Thought I'd stop messing around and ask for clarification before I make a bigger mess :-)

Thanks for any help. Oh and I love the bridge Orstio ! Thanks for all of your hard work.

Orstio

Installing a component does two things:

1)  It installs the files in the proper place.
2)  It configures the database so that Mambo knows where to find the files and how to handle them.

If you already have a component installed, and you want to change from the v2.11 bridge component to the one [Unknown] posted here, you need only to overwrite the files, because the database part is already taken care of by your original installation. 

If you already have a menu link to a component, and you uninstall that component, the menu item still exists in the database, but Mambo makes it inactive.  If you then reinstall, your existing menu item will not be reassigned to the new installation.  So, you will make a new menu item;  but when Mambo looks for the com_smf component in the menu list, it will find the inactive one, and you will have errors.

Both com_smf_1-0.zip and com_smf_1-0_ob.zip are replacements for com_smf.  They just work differently internally.

hshan

Thanks Orstio. So I guess the answer is... all of the edited files stay as they were for the original bridge. If I were to use unknown's component, I would merely overwrite them on the server via shell or ftp. I'm guessing that I wouldn't be able to install again via mambo admin backend, being that a com_smf is already installed?

What about my existing menu for com_smf, in the database, that is inactive? Should I delete it through phpMyAdmin? and then install a component again?

Are you saying that it is unrepairable... start over? It isn't really a big issue as this is a new site that I am setting up.

Orstio

QuoteSo I guess the answer is... all of the edited files stay as they were for the original bridge.

You mean the theme files?

QuoteWhat about my existing menu for com_smf, in the database, that is inactive? Should I delete it through phpMyAdmin? and then install a component again?

You mean you have already uninstalled the component?

QuoteAre you saying that it is unrepairable... start over? It isn't really a big issue as this is a new site that I am setting up.

I recommend never starting over.  I recommend not uninstalling to upgrade.  Just overwrite the files that come with the new package.  The database should not change from the original installation.

hshan


QuoteYou mean the theme files?
Yes that is what I meant, but I guess it is pretty obvious from here that all login2 and logout need to be changed to reference the mod_smf_login...   And same goes for index.english..php... it needs the original modification.

Quote
You mean you have already uninstalled the component?
Yes, I had already uninstalled the 2.11 version of the componant and then installed unknown's

Quote
I recommend never starting over.  I recommend not uninstalling to upgrade.  Just overwrite the files that come with the new package.  The database should not change from the original installation
Ok good. By overwrite do you mean by ftp overwriting the files? or via mambo componant install/uninstall

Thanks for your help Oristio... I know that you are very busy!

Orstio

QuoteYes, I had already uninstalled the 2.11 version of the componant and then installed unknown's

Then you'll want to check your mos_menu table for multiple entries of "index.php?option=com_smf" after you reinstall.  You will want to delete all but the last one.

QuoteOk good. By overwrite do you mean by ftp overwriting the files? or via mambo componant install/uninstall

By FTP.  Otherwise, you may end up with the above-mentioned problem.  Mambo's installation writes to the database....you do not need to change anything in the database to upgrade.  Therefore, to upgrade, it is better to not use Mambo's install/uninstall.

hshan

Thank you Oristio for your help.

Quote
Then you'll want to check your mos_menu table for multiple entries of "index.php?option=com_smf" after you reinstall.  You will want to delete all but the last one.

I'm using 4.5.1a of Mambo and it seems that when I delete a menu.. it throws it into mambo's trash. Going to the trash and deleting the menu seems to delete it from the database. I didn't see an entry there in the database, just my new one which I named differently.

QuoteBy FTP.  Otherwise, you may end up with the above-mentioned problem.  Mambo's installation writes to the database....you do not need to change anything in the database to upgrade.  Therefore, to upgrade, it is better to not use Mambo's install/uninstall.

I overwrote the files and as far as I can tell... all is working great. Thanks again for your help. I really appreciate all you are doing to get this integration going. I am seeing quite a bit of excitement on the mambo side too. And... i'm really glad that Unknown is taking an interest in lending his expertise to the project also. Wonderful work! Thanks to all.

[Unknown]

The package gave you a "modification parse error"?  Is it possible you downloaded or uploaded it badly?

-[Unknown]

Advertisement: