News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

SMF Mambo Bridge Login Error

Started by ditch1234, October 25, 2004, 12:26:18 AM

Previous topic - Next topic

ditch1234

First of all, I really love SMF.  I am switching from Phorum on a couple of sites and I four Mambo sites that have been using SimpleBoard.  SMF is far superior to both boards.

I did a clean install of Mambo and SMF.  SMF lives in a dir of the Mambo Web root.  everything seems to be fine, (needs some pretty heavy template work, but all works well) until a new user logs in.  Here is the error:

Warning: call_user_func(Login): First argument is expected to be a valid callback in /Users/ditch1234/www/components/com_smf/smf.php on line 46

It logs me in, but I get the above error, followed by what appears to be two SMF headers.  Or, one SMF header followed by a full SMF board.  It looks like it is choking on Mambo template display.

There is the com_smf login, and the login at the top of SMF that is wrapped in Mambo.  I guess the second is the actual SMF login.  If I use that login, it logs be into SMF and displays just fine, but it doesn't log me into Mambo, just SMF.

I'm pretty lost and frustrated. I know that once this is working, it will be worth the headache, but I am kind of at a loss right now.

Thanks fro any help you can give.

Orstio

QuoteWarning: call_user_func(Login): First argument is expected to be a valid callback in /Users/ditch1234/www/components/com_smf/smf.php on line 46

That's very strange.

Can you look at smf.php, and post the contents of line 46?

ditch1234

Quote from: Orstio on October 25, 2004, 12:44:36 AM
Can you look at smf.php, and post the contents of line 46?

call_user_func(smf_main());

Orstio

Thanks.

Can I see your site?  A URL would be nice.

ditch1234


Orstio

Well, it sounds like something in the bridge is not installed correctly, but I can't really tell what, or if I am correct, without seeing it in action.  :-[

ditch1234

I guess I should mention.  The bridge I am using was downloaded from MamboPortal.com [nofollow] (http://www.mamboportal.com/component/option,com_remository/Itemid,27/func,fileinfo/parent,folder/filecatid,1201/ [nofollow]).  

I assumed when I downloaded it that it was an official SMF bridge.  Now I am getting the impression there is no 'official' SMF bridge.  This one comes with several modules.  The downlaod comes from http://www.everything-science.com [nofollow], but there is no mention of the bridge in the board.  They are definitelty using Mambo 4.5.1/SMF RC2.  But nothing mentioned in their boards about this bridge attributed to them at mamboportal.


Orstio

QuoteThis one comes with several modules.  The downlaod comes from http://www.everything-science.com, but there is no mention of the bridge in the board.  They are definitelty using Mambo 4.5.1/SMF RC2.  But nothing mentioned in their boards about this bridge attributed to them at mamboportal.

"They" would be me. ;)  Everything Science is my website.  There is no mention of MamboPortal there, because Mambo really has nothing to do with the subject matter of the site.

MamboPortal would have copied the files I put at MamboForge:

http://mamboforge.net/frs/?group_id=543

You most likely have the correct files.  I just think that something was installed not quite right.  It's difficult to say what exactly is going wrong without trying it myself.

{EDIT} After looking at your screenshot, I have to ask -- where is your Mambo template?  It seems to be missing from the page.....

ditch1234

That's part of the problem.  The Mambo template dissapears, and all I get is what you see.

Look at this screenshot: http://www.causefx.com/screenshot2.gif [nofollow]

As you notice, there are two logins on the page.  If I use the login just below the Ka-Ching banner (com_smf login), I get the error in the previous screenshot.  If I log in to the lower login form, it logs me into SMF, but not into Mambo.

Orstio

You copied a piece of code into your Mambo template header.  Can you post that here?

Also, the contents you put in $smf_path?

ditch1234

I guess if you are they then I am talking to them.  It is nice to be talking to the source.  Thanks for your help.

ditch1234


ditch1234

Quote from: Orstio on October 25, 2004, 01:48:14 AM
You copied a piece of code into your Mambo template header.  Can you post that here?

<?
   require ("components/com_smf/config.smf.php");
    require ($smf_path . "/SSI.php");
?>
</head>

Quote
Also, the contents you put in $smf_path?

<?php

$smf_path = "snowboard";


?>

ditch1234

Big problem.  There is no SSI.php anywhere.

ditch1234

sorry, found it where it is supposed to be

ditch1234

Okay, I put that code in my template header, but I changed templates.  I just added the code to the SolarFlare template and I have a new issue.  I will get a screenshot and post it.  Stay tuned...

Orstio

SSI.php should have come with your SMF.  It should be in your "snowboard" directory.

On that error page, what is the query string?  It'll be all the code after index.php.

ditch1234

Quote from: Orstio on October 25, 2004, 02:04:25 AM
SSI.php should have come with your SMF.  It should be in your "snowboard" directory.

On that error page, what is the query string?  It'll be all the code after index.php.

?option=com_smf&Itemid=41&?action=mambo_login

New screenshot:  http://www.causefx.com/screenshot3.gif [nofollow]

There are now 3 logins.  (http://127.0.0.1/snowbird/index.php?option=com_smf&Itemid=41&?action=login [nofollow])

ditch1234


ditch1234

I am not trying to do this on a live site.  I could very easily start over and follow the install again.  Do you think that would be easier than trying to fix it?

If you feel like everything is there and should work, I probably just missed something.

Orstio

No problem.

OK, in your SMF settings, what do you have for the following:

Use database driven sessions

Enable local storage of cookies

Use subdomain independent cookies

Orstio

QuoteI am not trying to do this on a live site.  I could very easily start over and follow the install again.  Do you think that would be easier than trying to fix it?

If you feel like everything is there and should work, I probably just missed something.

What's happening now is that your cookie is not being set, and it is kicking you back to the SMF login page.  By adjusting the settings in the previous post, you can fix this.

ditch1234

Quote from: Orstio on October 25, 2004, 02:14:07 AM
Use database driven sessions

Selected

Quote
Enable local storage of cookies

Not Selected

Quote
Use subdomain independent cookies

Not Selected


I haven't changed anything in the settings.  all are default settings.

Orstio

Try it like this instead:

Use database driven sessions: Not selected

Enable local storage of cookies: Not Selected

Use subdomain independent cookies: Selected

ditch1234

I just went back to the install instructions.  I guess I missed what was right in front of my eyes.

I set them according to your instructions, but I still have the same problems.  I logged out and deleted cookies.  Logged in again and have the same problem.

ditch1234

I have nuked everything and started over.  I am following the readme.txt files very closely as I go.  In the mod_smf_login.php v2.o readme file, it says:

QuoteThis release comes with an additional file, MOS_SMF.php.  This file must be uploaded into your SMF Sources directory.  This release will not work correctly if the file is not in the correct place.

There is no MOS_SMF.php file in the distribution.  According to the readme file, this is my problem.

What do you think?

Orstio

#27
Yep, that'll do it too.

Download the 2.01 from here, and try that:

http://mamboforge.net/frs/?group_id=543

It definitely has MOS_SMF.php, inside MOS_SMF_Integrated_login.zip

{EDIT} I just downloaded the one from MamboPortal, and MOS_SMF.php is there.

[Unknown]

You know, using smf_api.php you could mess with sessions the database-driven way.  Otherwise, maybe installing the bridge should force them off?

-[Unknown]

Orstio

Actually, I have database driven sessions turned on at my site, and it is working fine.  I just suggest turning it off, because the login seems to be affected by it.

SMF sessions and Mambo sessions don't seem to like to play nice together in all instances.  ???

[Unknown]

In that case, you could try directly modifying the data in smf_sessions.

-[Unknown]

silentbob

http://sweepthis.com/mambo/index.php?option=com_smf&Itemid=44 <-- could someone tell me what this means and perhaps how to fix? thanks!

bmwheaven

Hi guys,
I've been busy with the bridge as well, but it seems that something goes wrong....
I've got Mambo, SMF and coppermine.
I bridged Mambo with SMF and the I bridged SMF with Coppermine.
Now when I loging with the mod_smf_login module, it only logs me in to SMF and Coppermine, not in Mambo.
To show you what's going on, go here: http://bmwheaven.bmwsport.net/mambo
There are 2 login boxes on the right side, you can login with user: test, pass: test.
Thanks for the help, dunno what I'm doing wrong.
(ow yeah, the site is in beta beta stage :) )
Sh*t happens
All the time

Kindred

First,

You forgot to UNPUBLISH the Mambo-standard login module...

Question: How can you tell if a user is logged in to Mambo?
(in mine, I have a module listing members and guests online)

Question: If you leave someone logged in for 30+ minutes, does Mambo recognize the user login then?   That is what has been happening on my site. (We've been discussing this in a couple of different threads)
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

bmwheaven

well,
to answer your questions...

i put the 2 login modules on purpose on my site, just for testing, but as you can see that if you login to one, the other one still thinks you're not logged in....

And to test if you're logged in to mambo, you should see the link "User List" next to "Image Gallery" in the top links....
So if you login to the mod_smf_login you aren't logged in to the mambo system, because you cannot see "User List" (which is for registered users only).

Any idea's????

[edit] owh yeah, thanks for the reply :) [/edit]
Sh*t happens
All the time

Kindred

try unpublishing the mambo login
then log in to the SMF bridge with "forever" selected.

wait 30-60 minutes
come back to the site
check if the user is logged in to Mambo at that point.

Question: In SMF, what do you have set for:

Subdomain independent cookies
local cookies
database driven sessions
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

bmwheaven

Ok,
before trying the above, the settings for SMF:
Subdomain independent cookies = OFF
local cookies = OFF
database driven sessions = ON

After your reply to this (maybe I have to change it), I'll delete all my cookies, and login to SMF, then return in an hour, and post here....
Sh*t happens
All the time

bmwheaven

K, tested it with the same settings as above, and you're right...
It does log in after a certain amount of time....
I'll keep track of the other topic on this (the one with the 24 pages :) )
Thanks for the help!
Sh*t happens
All the time

Advertisement: