Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Options

A Tale of Two Vanillas

edited February 2007 in Vanilla 1.0 Help
I've got two Vanillas: One is a forum and the other is being turned into a blog. I was wondering if they both could have separate databases, yet use the same table for all user info.; in other words, work independantly as far as posting is concerned, but users would not have to register twice to use both. What would I have to do to make this work?

Comments

  • Options
    MarkMark Vanilla Staff
    Assuming you're installing both applications from scratch:

    You'd need to set up the first database and then change the table prefix on all tables to something else. Delete LUM_User. Then install the other forum and leave all db tables as they are.

    Open up your conf/settings.php file for the first app and add/change the DATABASE_TABLE_PREFIX variable to reflect the new prefix you used.

    both apps should then be using their own tables for everything but user accounts. After that you can let the users sign in on different people.php pages or you can have them go to the same one with a few other configuration changes if you want.
  • Options
    edited July 2006
    Okay, I got all of that done. Thanks! I just have one small problem to over come: the CSS isn't being applied after you sign in to one of the forums--it works on the other. Everything is fine until you sign in. I have checked settings.php and everything seems in order in the forum in question. I checked the source and for some reason the css path gets cut off after sign in, it reads /vanilla.css instead of /blog/themes/vanilla/styles/default/vanilla.css.
  • Options
    MarkMark Vanilla Staff
    Is that on a modified theme?
  • Options
    Yes
  • Options
    MarkMark Vanilla Staff
    I'd take a look at the original theme file and see if you changed that part of the theme so that it doesn't call the same method as the original. You might have accidentally removed something.
  • Options
    I went ahead and reinstalled the theme since most of the changes I made were minor and the big stuff is in extensions. I have the same problem...Could I do a fresh install of Vanilla?
  • Options
    I get the same behavior when I have two forums share a user table but have different themes applied.

    Interestingly, it only happens when I log in.
  • Options
    by any chance do you have style definitions extension on? i cant think of anytihng else.
  • Options
    I just did a fresh install of Vanilla on the problem forum and nothing changed. There is something wrong with the way vanilla.css is called when the sign in occurs. I haven't used the style extension.
  • Options
    MarkMark Vanilla Staff
    You know what I bet it is?

    The LUM_Style table.

    The user account has a StyleID field that tells the app which style to load from LUM_Style. For the first app, it is loading the correct style, but the other app is trying to retrieve the same ID from a different table (where, perhaps, there isn't an entry yet). The key to making it work would be to make sure that the second app has a valid entry in it's style table with the id in StyleID on the user table.
  • Options
    edited July 2006
    That was the problem. I went in and made sure the LUM_Style contained the correct path, then made an entry into WHATEVER_Style with the correct path and everything worked. It feels good to get these things figured out.
  • Options
    MarkMark Vanilla Staff
    Huzzah!
  • Options
    TexTex
    edited January 2007
    I used this method and everything worked out fine. Except one problem:

    I am logged in to both vanillas. After some hours without visiting any of them, I am logged out at the first one. Going to the second one I am logged in, going back to the first one being logged in again automatically (using links to go from one to another).

    Anybody with the same problem and a solution?
  • Options
    Do your forums share the same cookies? Check out both configuration files (conf/settings.php) and make sure they use the same cookie path.
  • Options
    TexTex
    edited January 2007
    Now they do. I'll see if this helps, but I am certain you know what you do. :)
    Thank you, Jazzman.

    Edit: Just wanted to say that the hint of Jazzman worked.
  • Options
    TexTex
    edited February 2007
    The problem occurs again. I got no idea why it seemed to be solved and now doesn't seem to work anymore. Any further suggestions?

    Edit: I moved to another server and it seems to work again.
This discussion has been closed.