News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Mambobridge SQL Error

Started by ILIKEKETCHUP, July 16, 2005, 01:06:43 AM

Previous topic - Next topic

ILIKEKETCHUP

Nevermind. This topic solves the problem.
http://www.simplemachines.org/community/index.php?topic=39641.0


-----------------------------
Mambo v4.5.2
SMF v1.0.5
MOS_SMF_Bridge v3.19a

I followed the step by step instructions for installing Bridge, and got everything installed successfully. I have saved each component and module that was added. I unpublished the old Mambo login, and published the new bridge login. The new login appears on my page, but just above the name/password fields I have this error:

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/blah/public_html/modules/mod_smf_login.php on line 19

I looked at the line 19 code on mod_smf_login.php, and it says this:

if (isset($result)){$row = mysql_fetch_array($result);}

If anyone has any suggestions I would appreciate it. I haven't been able to find anything on the forum referencing this particular error.

Thank you,

Steve


Kindred

This is probably one of these four problems....

1) you did not add the code into your mambo template index.php as instructed in step 4.
2) you do not have a public menu item pointing to com_smf
3) you do not have guest access turned on in SMF
4) You have two separate databases, but have not given both db users access to the other database.
Сл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."

G-Force

Quote from: Kindred on July 16, 2005, 09:27:14 AM
This is probably one of these four problems....

1) you did not add the code into your mambo template index.php as instructed in step 4.
2) you do not have a public menu item pointing to com_smf
3) you do not have guest access turned on in SMF
4) You have two separate databases, but have not given both db users access to the other database.

I'm getting this error and I've followed these 4 suggestions that are listed here and I'm still having the same problem.

1) I've added the 2 snippets of code
2) A menu item in my top menu is pointing to       Component - SMF - Forum and it has public access.
3) Guest access is on in SMF
4) Yes, I have 2 separate mysql databases and I have the same userid/password on both the smf and mambo databases.

Based on what I've read in this post and others, I'm not sure what else could be wrong. My forum is located at http://gregforcey.com/forum
Currently the login module is unpublished on my mambo portion of the site. Thanks for any suggestions.

Orstio

This is what I get from your forum:

QuoteConnection Problems
Sorry, SMF was unable to connect to the database. This may be caused by the server being busy. Please try again later.

G-Force

Quote from: Orstio on July 30, 2005, 06:16:05 AM
This is what I get from your forum:

QuoteConnection Problems
Sorry, SMF was unable to connect to the database. This may be caused by the server being busy. Please try again later.

Where on my forum are you getting this message ??? I've tried the link in my previous post on two computers with three different web browsers and it loads fine for me.

Orstio

#5
The forum seems to be working now.

Quote4) Yes, I have 2 separate mysql databases and I have the same userid/password on both the smf and mambo databases.

This is where I think your problem lies.  In your SMF admin panel, under Server Settings, check, and write down, the database username and password.

Now go to your Mambo admin panel, Global Configuration>Server tab, and write down the database username and password from there.

Are they identical?

G-Force

Quote from: Orstio on July 30, 2005, 04:46:19 PM

Are they identical?

Yes, the userid and password are identical. I even copied the password in mambo to the clipboard and pasted it into the password field when I tried to access my smf and mambo databases through phpmyadmin just to make sure they were identical. Any other ideas? Thanks for offering to help, btw.  :)

Orstio

In PhpMyAdmin, check your mos_menu table.  Is there an entry where index.php?option=com_smf appears in the link column?  From what I am seeing on your site, it should be entry 10.  Can you confirm that?

Can you also make sure to empty your Mambo trash?  That can sometimes cause complications.

G-Force

Alright, I emptied the trash. There was one item in there but there but that didn't seem to solve anything. I did confirm the entry in phpmyadmin as you said and it is entry 10. However I still get the same error message when I publish the login module on the main page.

Orstio

OK, what kind of site control panel do you have?

G-Force

My site is hosted though Dreamhost and they have their own custom-built site control panel. See: http://www.dreamhost.com/panel/

Orstio

That may be the problem, then.

There are some site control panels that will not allow the use of two databases with the bridge.  I have only run into two so far...yours may be the third.

G-Force

Alright well isn't that the pits. So using smf and mambo on the same database would be a workaround then? Are there any disadvantages to this? Thanks for all the help

Orstio

Using one database instead of two has its advantages and disadvantages.

It will be easier to maintain your database, and make backups, if your site doesn't grow horrendously in the near future (like thousands of forum posts each day).

For very large sites, I would recommend two databases, because one would just be completely unmanageable.

Advertisement: