Welcome, Guest. Please login or register.
March 21, 2010, 10:55:11 AM

Login with username, password and session length
Search:     Advanced search
WB 2.8.1 released!
Download and additional information are available here .
110578 Posts in 15968 Topics by 9313 Members
Latest Member: Gudrun
* Home Help Search Login Register
+  WebsiteBaker Community Forum
|-+  English
| |-+  Modules (Moderators: Argos, BerndJM)
| | |-+  Website Baker and Vanilla, Together!
Pages: [1] Go Down Print
Author Topic: Website Baker and Vanilla, Together!  (Read 10339 times)
Steven Holder
The Template Master

Offline Offline

Posts: 493



WWW
« on: October 11, 2007, 08:50:20 PM »

Long time no see WB community! Im back from the dead it seems with some scripty goodness for all of you.

I was talking to hudge yesterday and he asked me to do some WB work for him and I decided to take a crack at it. I visited the WB Forums and saw that we still hadn't fixed the lack of a message board / discussion system for WB and I set myself to fixing that problem this morning.

I was looking at Vanilla, a discussion system, and saw that they had integrated it into WordPress
quite nicely and I decided to do the same for WB.

Here are the steps to getting a vanilla discussion board to use WB's user database so that your users only have to register once.

You can download vanilla at http://www.getvanilla.com


1. Install Website Baker
For this example you will install it to /public_html/
Use the WB install script at http://www.yoursite.com to install WB

2. Install Vanilla
Install the vanilla distribution so that it its files are located in /public_html/vanilla
Run the install script at http://www.yoursite.com/vanilla to install vanilla

3. Now comes the tricky parts. Firstly, download the files needed to integrate vanilla at http://www.hackvoid.com/Vanilla2WB.rar

4. There is a vanilla folder in the zip, unzip it and place the contents into your vanilla folder, there I did all the hard parts for you Smiley Open up vanilla/conf/database.php and enter the database information that you used during your installation.

5. Now Open up phpmyadmin and run the following query on your WB Database.
Code:
ALTER TABLE users
  ADD `RoleID` int(2) NOT NULL DEFAULT '3',
  ADD `StyleID` int(3) NOT NULL DEFAULT '1',
  ADD `CustomStyle` varchar(255) DEFAULT NULL,
  ADD `FirstName` varchar(50) NOT NULL DEFAULT '',
  ADD `LastName` varchar(50) NOT NULL DEFAULT '',
  ADD `VerificationKey` varchar(50) NOT NULL DEFAULT '',
  ADD `EmailVerificationKey` varchar(50) DEFAULT NULL,
  ADD `UtilizeEmail` enum('1','0') NOT NULL DEFAULT '0',
  ADD `ShowName` enum('1','0') NOT NULL DEFAULT '1',
  ADD `Icon` varchar(255) DEFAULT NULL,
  ADD `Picture` varchar(255) DEFAULT NULL,
  ADD `Attributes` text NULL,
  ADD `CountVisit` int(8) NOT NULL DEFAULT '0',
  ADD `CountDiscussions` int(8) NOT NULL DEFAULT '0',
  ADD `CountComments` int(8) NOT NULL DEFAULT '0',
  ADD `DateFirstVisit` datetime NOT NULL DEFAULT '2006-06-06 00:00:00',
  ADD `DateLastActive` datetime NOT NULL DEFAULT '2006-06-06 00:00:00',
  ADD `RemoteIp` varchar(100) NOT NULL DEFAULT '',
  ADD `LastDiscussionPost` datetime DEFAULT NULL,
  ADD `DiscussionSpamCheck` int(11) NOT NULL DEFAULT '0',
  ADD `LastCommentPost` datetime DEFAULT NULL,
  ADD `CommentSpamCheck` int(11) NOT NULL DEFAULT '0',
  ADD `UserBlocksCategories` enum('1','0') NOT NULL DEFAULT '0',
  ADD `DefaultFormatType` varchar(20) DEFAULT NULL,
  ADD `Discovery` text,
  ADD `Preferences` text,
  ADD `SendNewApplicantNotifications` enum('1','0') NOT NULL DEFAULT '0';

6. Okay, so now we need to make Vanilla aware of my our authentication class that I wrote, you uploaded it in step 4. I do this by editing the vanilla/conf/settings.php file and adding the following lines:
Code:
$Configuration['AUTHENTICATION_MODULE'] = 'People/People.Class.WBAuthenticator.php';

7. Now the last part do another query to your database and run these 2 queries, where your see <url>, write the URL to your websitebaker website.
Code:
INSERT INTO `settings` (`setting_id`,`name`,`value`) VALUES (NULL,'site_url','<url>')
Code:
INSERT INTO `settings` (`setting_id`,`name`,`value`) VALUES (NULL,'home','<url>')

8. Now, to give your default account admin permissions in Vanilla, run this query.
Code:
UPDATE `users` SET `RoleID`=4 WHERE `user_id`=1

You are done! Congratulations!

I just wrote this stuff this morning and have only tested it briefly. If you have any problems or if I left out any steps, post your error here and I will fix it.

You can see a demo @ http://www.hackvoid.com/test, sign up via wb or vanilla and you can log into either vanilla or wb.
« Last Edit: October 13, 2007, 10:18:16 PM by Steven Holder » Logged
doc

Offline Offline

Posts: 3581


« Reply #1 on: October 11, 2007, 09:01:23 PM »

Hi Steven,

think lot of WB members like to see a forum which nicely integrates with WB. Will try to test it the next couple of days and provide some feedback next week.
Anyway, thanks for your contribution - highly appreciated.

Regards Christian
« Last Edit: October 11, 2007, 09:07:30 PM by doc » Logged
Vincent

Offline Offline

Posts: 316


WWW
« Reply #2 on: October 11, 2007, 09:27:02 PM »

Good to see your name again, Steven. It's been a long time!
Looks like a valuable contribution, thanks.

Vincent
Logged
marathoner

Offline Offline

Posts: 491


« Reply #3 on: October 13, 2007, 12:01:26 AM »

Thanks Steven...agreed that it's nice to see you back.

Question for you: Have you put together any snippets that extract Vanilla data to be used in WB? I guess what I'm looking for is something that would allow me to put the title of the 5 most recent Vanilla posts (with links) on my WB home page. I current do this with SMF. I'm sure that I could figure out how to do it but don't want to reinvent the wheel if you've already done this.
Logged
Steven Holder
The Template Master

Offline Offline

Posts: 493



WWW
« Reply #4 on: October 13, 2007, 09:56:00 PM »

I haven't made a script that pulls headlines but I am sure it wouldn't be that hard to do. Just use the LUM_Discussion table and pull fields that you need out of it.

http://farm1.static.flickr.com/210/449220185_6559566740_b.jpg

That is the database scheme for vanilla so it makes it easy to manipulate their database.
Logged
DGEC

Offline Offline

Posts: 382


WWW
« Reply #5 on: October 16, 2007, 11:17:55 PM »

Looks like a pretty nice forum. A couple issues I see, for some people.

1. There's a still a bunch of functionality that isn't there yet. I think I was reading the roadmap or future plans or something when I saw that.

2. I suspect the forum or default template has a browser compatibility issue - it keeps locking up IE7. I believe I read recently something about the Yahoo toolkit having a JS issue/error that would result in repeated reloads of the page. It couldn't find some file I think. Not sure if it's the same thing or not.

3. Maybe it's #2 or maybe it's all the AJAX, but it feels a bit slow rendering the page.
Logged
Revive

Offline Offline

Posts: 28


« Reply #6 on: March 03, 2008, 12:16:39 AM »

Hello,
I have a couple questions regarding an error upon install.

1) when I placed the Vanilla files in the vanilla folder on my root install, and then went to www.website.com/vanilla, i get this error:

Fatal error: Call to undefined function: show_menu2() in /home/passanie/public_html/revivecoffeehouse/pages/vanilla/templates/daybreak/index.php on line 36

Also, in regards to the files within the hackvoid zip.. do I place just the contents of the vanilla folder from the zip into the vanilla install folder? Or do I place the complete vanilla folder form the zip (folder and contents) into the vanilla install folder?

Thanks again, we look forward to using your script!
Logged
Steven Holder
The Template Master

Offline Offline

Posts: 493



WWW
« Reply #7 on: March 07, 2008, 03:26:44 AM »

When you unzip the package file, all the files in the vanilla folder are already in the right places, just drag and drop ontop of your vanilla directory.

And I haven't tested this with any other templates except the default one, so I'm not sure about the first error, I will look into it later.
Logged
Revive

Offline Offline

Posts: 28


« Reply #8 on: March 07, 2008, 04:34:45 AM »

Hi Steven,

Excellent, thank you. Yes, I installed the directory just as unzipped. As for the error,.. it is probably something to do with the Show_Menu2 module.. from what it reads.. not sure why though. Anything I can do to assist with this, please let me know.
Logged
vinny84

Offline Offline

Posts: 5


« Reply #9 on: March 07, 2008, 11:12:32 AM »

I have Many roles in my WB can have the default set to a particular group 1 o 2 o....

can some 1 send me the steps of doing this please

thanks in advance

Cheers
Vinny
Logged
Steven Holder
The Template Master

Offline Offline

Posts: 493



WWW
« Reply #10 on: March 23, 2008, 09:50:52 PM »

You can download WinRAR for free at http://www.rarlab.com/download.htm

Logged
tsb

Offline Offline

Posts: 37


« Reply #11 on: March 24, 2008, 03:40:02 PM »

got the rar now open,

I quoted the stuff in myphpadmin, through something like sql, im not up on database editing, yet everything seemed to be accepted.

 I had some bother getting the right address for the settings in conf, yet once that was done, everything is done without any visible glitch, it doesnt seem to know me if I login however, or try to login, it just goes back to the normal address, with sign in in the right corner, which should have my name, have I put the wrong address in anywhere? or a page to look at, as I say, Im a novice in this part,

hope my problem makes sense, cheers,
Logged
Steven Holder
The Template Master

Offline Offline

Posts: 493



WWW
« Reply #12 on: March 24, 2008, 04:26:07 PM »

When you executed the query

Code:
INSERT INTO `settings` (`setting_id`,`name`,`value`) VALUES (NULL,'site_url','<url>')

You changed the <url> to the url of your website, like http://example.com right?
Logged
tsb

Offline Offline

Posts: 37


« Reply #13 on: March 24, 2008, 05:08:38 PM »

I just put in www.strudal.co.uk, my address without the http:// part,  can I overwrite in the myphpadmin?
Logged
mehdi

Offline Offline

Posts: 1


« Reply #14 on: March 25, 2008, 07:17:31 PM »

it works
 great!
is there any way that users be logged in  automatically to forum if they have been logged before in WB ?
Logged
spawnferkel

Offline Offline

Posts: 66



WWW
« Reply #15 on: April 09, 2008, 11:24:50 AM »

Hey mehdi,

did you or someone else found a solution?
>>is there any way that users be logged in 
>>automatically to forum if they have been logged before in WB ?

But I am very happy with the vanilla-connection! Great! Thank you Steven!
Logged

I would like to improve my english knowlege and I would really appreciate if you give me some feedback if I make some rough grammar mistake.
vinny84

Offline Offline

Posts: 5


« Reply #16 on: April 25, 2008, 01:05:03 AM »

Hello I got this error.
all my web baker tables have a prefix of wb can some 1 help when do i modify this to get it working

---
A fatal, non-recoverable error has occurred
Technical information (for support personel):

Error Message
    An error occurred while retrieving discussions.
Affected Elements
    DiscussionManager.G etDiscussionList();

    The error occurred on or near: Table 'WebBaker.users' doesn't exist

For additional support documentation, visit the Lussumo Documentation website at: lussumo.com/docs

----
waiting some suggestions.

cheers
Vimal
Logged
Steven Holder
The Template Master

Offline Offline

Posts: 493



WWW
« Reply #17 on: April 25, 2008, 10:24:54 PM »

Just a guess, but when you edit your database.conf file, you should probably have Vanilla look for wb_users and not users. Smiley
Logged
vinny84

Offline Offline

Posts: 5


« Reply #18 on: April 26, 2008, 07:49:41 AM »

Thanks
Logged
slafochmed

Offline Offline

Posts: 1


« Reply #19 on: August 18, 2008, 05:03:46 PM »

I did a fresh websitebaker 2.7 and vanilla 1.4.4 install and I am getting the following error:

Quote
Error Message
    An error occurred while retrieving cookie names.
Affected Elements
    WBAuthenticator.Get CookieName();

    The error occurred on or near: Table 'vanilla.settings' doesn't exist

For additional support documentation, visit the Lussumo Documentation website at: lussumo.com/docs
« Last Edit: August 19, 2008, 01:26:43 PM by slafochmed » Logged
kerrodhall

Offline Offline

Posts: 1


« Reply #20 on: August 26, 2008, 10:29:38 AM »

The "off-the-shelf" installation looks for the wb tables without any prefix (i.e. looks for the table called "users" instead of "wb_users").

You need to open up the /vanilla/library/People/People.Class.WBAuthenticator.php and edit the following lines:
Code:
132:        $s = "select user_id, password from users where username = '".FormatStringForDatabaseInput($login)."'";
and
Code:
166:        $s = "select name, value from settings where name = 'siteurl' or name = 'home'";

replace them with the following:
Code:
132:        $s = "select user_id, password from tm_users where username = '".FormatStringForDatabaseInput($login)."'";
and
Code:
166:        $s = "select name, value from tm_settings where name = 'siteurl' or name = 'home'";



I had the same problem, but it almost completely works now. Only problem is, it doesn't seem to detect the cookie and my users have to log into the forum again (even after they logged into the site).



The other alternative is to start again and this time dont set a table prefix.

Cheers,
KH
Logged
xyloweb

Offline Offline

Posts: 12


« Reply #21 on: September 06, 2008, 04:08:07 PM »

I just put in www.strudal.co.uk, my address without the http:// part,  can I overwrite in the myphpadmin?
Quote
You changed the <url> to the url of your website, like http://example.com right?
Yes to both questions.
Make sure you do not add an ending "/" to the site name.  That didn't work for me.  (It caused an authentication error when trying to make changes via the web interface.)

FYI: Actually, I didn't need to run the two INSERT queries - I just edited existing records in the DB via PHPMySQLAdmin.
Logged
Hoco

Offline Offline

Posts: 21



« Reply #22 on: October 30, 2009, 08:15:47 PM »

Dear WB-programmers,

Since 2007 I've got a website, running under the good, easy-to-use, easy-to-support Websiitebaker. Since that day, I'm looking for a easy-to-install and easy-to-support Forum-module.

I've found three attempts: JK-forum, WB-forum and a "vanilla-solotion".

http://www.websitebaker2.org/forum/index.php/topic,12307.0/topicseen.html
http://www.websitebaker2.org/forum/index.php/topic,15071.0.html
http://www.websitebaker2.org/forum/index.php/topic,7537.0.html

Please, can someone tell me, which is easy to install, stable to use and uses the identification of the backend ?

And if you can advise one, leave a link so I can check it out !

Hoco  undecided
Logged

Let's bake some sites and don't get burned
erpe

Online Online

Posts: 1738



WWW
« Reply #23 on: October 30, 2009, 08:55:40 PM »

http://www.websitebakers.com/pages/modules/interaction/wb-forum.php

rgds

erpe
Logged

Pages: [1] Go Up Print 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC Valid XHTML 1.0! Valid CSS!