Drupal Forums instead of phpBB or vBulletin: A casestudy

2019-03-27 01:07|来源: 网路

 

5th Jan, 10

For years I have been using phpBB for a busy community website that has over 162490 registered members. It has been a great ride, members are happy with the functionality and ease of use BUT from a development and security point of view it has been a painful experience.

As anyone who has ever installed, hacked and setup phpBB forum will tell you that due to the lack of hooks or modular nature of phpBB you have to hack core to add any additional functions. Prior to Drupal this was "acceptable loss" to me, but I have "come to my senses" and it is something that I would hate to do now.

For one of the work websites (www.mychild.co.uk) that is currently running on Drupal 5, we decided to expand the website and expand it to incorporate a forum. Fun times!! After much deliberation and discussions about pros and cons of each package, here is a "must have" that we decided upon:

Must have features
  • Forums must share the same login as Drupal site
  • MUST look and feel like a phpBB/VB forum
  • Private Messenging
  • Private Forums (moderate only - access by role)
  • Email notifications of updates/comments
  • Avatars
  • Post count (in profile and forum posts)
  • Star Ranking (based on post count)
  • Rank Badge (based on role)
  • Custom folder icons (keeping the look and feel close to phpBB)
  • New posts since last visit
  • Custom breadcrumb
  • Banner blocks
  • Ability to cross promote other drupal content types (based on term relationships)
  • Attachments in comments (with limit)
  • Quote
  • Banwords
  • Offsite links open in a new window
  • Advanced search

It quickly became apparent that we were no longer looking at a standalone Forum package for which I could bridge the login/session with Drupal. Since we wanted to bring majority the Drupal and custom functionality over to the forums Drupal Forums was the way ahead.

So, how do you go about achieving the above with Drupal? Easy. Well, sort of easy. Drupal Forums are very basic out of the can. It is basically a node with comments enabled. Without going into coding specifics at this stage, here is a brief outline on how we added some more meat to the Drupal Forums, I installed the following helper modules to mimic a "proper forum":

Modules used
  • Advanced Forum
  • Author Pane
  • BBCode
  • Comment upload
  • Extended user status notifications
  • Flat comments
  • Quote
  • Upload max files
  • Signatures for forums
  • User badges
  • User Stats
  • Word Filter
  • Smileys
  • Subscriptions
  • jQuery Update
  • External Links
  • Forum Access
  • Abuse
  • Apache Solr
  • Statistics
  • Private messages

The above modules provided around 80% of the missing functionality. The remaining bits and pieces were down to writing my own custom modules and a custom theme for Advanced Forum. If the website had been running Drupal 6, we could have pushed the boat out even further, but that is for another day.

If you have any specific questions or coding queries, please post a comment and I will try to answer.

Now, for some screen shots:

Forum Home Page

Forum Node & User Info

Forum Stats

User Profile

Forum Private Msg

Your thoughts, feedback and comments are most welcomed.

Related blog posts: 

Drupal 5 - Disable FCKEditor per content type

Drupal 6: Define SEO Meta Tags dynamically using hook_nodewords_tags_alter

ApacheSolr search for Drupal on CentOS

Drupal 5: fix comment permalinks with pagination

Adding Custom Breadcrumb for Drupal nodes

Bookmark and
 Share

20 comments

Anonymous's picture

Eric
5th Jan, 10

A very useful post - I am in a similar situation. My site is using phpBB hooked into Drupal with one of the bridge modules. I would like to move to a Drupal only setup... at some point I need to migrate the old forum into Drupal.

I don't think it will be fun. Any thoughts on migrating the posts?

Also, do you allow attachments to forum posts/comments/

Eric

»

Janak's picture

Janak
5th Jan, 10

Hi, migrating posts from phpbb v2 and v3 to Drupal is possible using the importer module that comes bundled in with the phpbb-to-drupal bridge module. However, if you are using Drupal 5, there is no importer from phpbb v3, sadly you will have to write your own (upgrade module?) or upgrade your installation to drupal 6.

Yes we allow comment attachments, I am using the Comment upload module for that. For attachments on the nodes, you can either use cck filefield or the core upload module. I am using cck filefield as it allows me to specify a dedicated folder for forum uploads.

»

Anonymous's picture

Craig
5th Jan, 10

I've been considering making the move from vBulletin to Drupal for a large community site I run. However I'm curious about performance. I have 100k threads, 1.2M posts, 33k users and get around 65k unique hits / day (most from anonymous) users. How has the performance of your Drupal site faired?

»

Janak's picture

Janak
5th Jan, 10

As with any big Drupal site, performance is a concern if you are not on a dedicated server. Luckily, for the work sites we have 1 dedicated web server, 1 dedicated file server and 1 dedicated DB server. On top of that we are using OP Cache (Xcache) and mysql caching. Without which I am sure the servers would struggle to cope with the resource hungry beast that Drupal can be.

Although it is not a common practice on forums to cache the pages for anonymous users, we did implement a page cache of 10-15 min. This is to minimise resource drain due to anonymous trafic and also to add an incentive for the users to become a registered member.

So, I guess it will ultimately depend on what resource you have and also if there is a financial benefit to having a seamlessly integrated forum with the drupal website. If there is no "real" benefit or requirement to have seamless integration, it might be better to run a phpBB/VB package on a subdomain. I guess it all depends on what you are trying to do and how valuable you deem the community is to your main website!

For a forum only website that needs to run on a shared host, drupal might not be the ideal solution! It all depends...

»

Anonymous's picture

Michelle
5th Jan, 10

Nice writeup! It's too bad you're still on Drupal 5. AF 2.x gets a lot closer to the "expected" forum experience. Looks like you did a real nice job, though. I like your forum style.

Michelle

»

Janak's picture

Janak
5th Jan, 10

Thanks Michelle, without Advanced Forum and all other addon modules it wouldnt have been as easy.

In an ideal world we should have upgraded to D6 but we have so many custom modules on the website (banner system, co-reg system, lead collection, payment gateways etc etc) that it would have turned out to be a much bigger project. So sadly we have to make do with D5.

D6 upgrade is on the cards for this quarter of the year, lets see how smooth that goes. We needed to get something off the ground quickly and test the waters to see if it is something that we want to pursue long term, so a big thank you to you and all the team behind all the modules that I had to rely on :)

»

Anonymous's picture

Adrian
6th Jan, 10

What are the remaining 20% functionality required to write custom modules ?

»

Janak's picture

Janak
6th Jan, 10

its mainly:

- Star Ranking (based on post count)
- Custom folder icons (keeping the look and feel close to phpBB)
- New posts since last visit
- Custom breadcrumb
- Ability to cross promote other drupal content types (based on term relationships)
- Custom theme
- Online members
- Hall of fame

»

Anonymous's picture

Eelke
6th Jan, 10

I'd be very interested to learn how the user experience is, both for site users and site staff. I am in a similar situation, although my site is not yet in production, I am developing a site based on both Drupal and phpBB. I have shied away from trying to duplicate phpBB functionality in Drupal because of the sheer number of extra modules that would be required (and the associated evaluation work). Incidentally, I don't see having to "hack" phpBB as that big of a deal; having a good version control system up and running, that allows you to merge in changes from one version of phpBB to the next, is 80% of the headache gone. Of course a hooks system is better and there is a clear trade-off here, but for me, the sweet-spot still seems to be a bridge solution. But again, I would be interested to learn how the user experience is; if there is a pre-made list of Drupal modules that will result in functionality close or equal to a "proper" forum, that's a lot of the work already done.

»

Anonymous's picture

Michelle
9th Jan, 10

Weird... This looks threaded but there's no reply links. Anyway, this is to Eelke:

http://drupal.org/node/227121

Michelle

»

Janak's picture

Janak
11th Jan, 10

thats odd, you should be able to see "reply", I'll check. Cheers for the link btw.

»

Anonymous's picture

Murali
7th Jan, 10

Hi Janak:

Looks great.

What is the style you used?

Thanks,

Murali.

»

Janak's picture

Janak
7th Jan, 10

thank you. This was a custom style I made for to match the website! You can take one of the default Advanced Forum themes and easily customise that I suppose!

»

Anonymous's picture

Pat Campbell
9th Jan, 10

Great post, very helpful. Am trying to get a forum running on my site at the moment. Having trouble getting author pane working but it is coming along.

Any reason you are using Drupal 5? I am too but it was initially so I could get the phpBB integration working smoothly (which I ditched anyway to go with this method)

Do you also know if there is a way to create a back button without using breadcrumbs when you are looking at a thread? There seems to be one missing.

PS: How are you doing the nice jQuery comment submission?

»

Janak's picture

Janak
11th Jan, 10

Look fwd to seeing you work, please drop a link here when your site is live.

We have a lot of custom modules that are mission critical and it will take a while to upgrade them all! We didnt want to delay the launch of the forum until that upgrade happens.

Sorry, back button to go back to where? The main forum listing page or the forum (taxonomy term) itself? Either are possible and I think they might be implemented in D6 version of advanced forum already! If not, I might be able to help you figure out the code.

jQuery Comments are done using this wonderful AJAX Comments module by neochief

»

Anonymous's picture

Todd
11th Jan, 10

Amazing writeup....did you send your theme to drupal garden or upload back to community?

Great work!

»

Janak's picture

Janak
11th Jan, 10

No this one was quite a custom theme for MyChild website and wasnt really developed with drag-drop functionality in mind. You can quite quickly modify one of the Advanced Forum stock theme to mimic what you see here. Besides, D6 branch of Advanced Forum is already much better and I guess the theme is very close to a "proper forum" look and feel!

»

Anonymous's picture

David Sanchez
13th Jan, 10

Nice post. I'm running a large forum site with Simple Machines Forum (SMF), which I'm planning to switch for Drupal. However, first I need to convert to PHPBB, then Drupal. I'd like to know if you had problems with the passwords when converting from PHPBB to Drupal?

Also, most forums have the possibility to jump directly to the "Last post" from the Boards index. In Drupal, this option brings you to the page Index, where you have to manually look for the last post. Could you solve this problem?

Cheers

»

Anonymous's picture

Pat Campbell
17th Jan, 10

Hey there,

http://student-in-law.com/forum/ is my Advanced Forum, with most of the theming done (much helped by your site as an example of where to find the relevant lines of CSS that I had trouble locating).

Am having two major troubles though. Post reply button does not work, the comment/post form does not display when it is clicked. Also, the author panel still is not showing up on people's posts. Infuriating! Any ideas off the top of your head what that could be? Is my panel too narrow? I don't quite get it.

»

Anonymous's picture

Steward
24th Feb, 10

Hello Janak,

i just visited mychild - great site! and the first time, that I consider in keeping the drupal forum. One question: How did you manage it, that the link "last post" on a page like http://www.mychild.co.uk/forum/welcome-to-the-forum-1848 contains the "...page=14..."? We use 'speaking urls' but if the number of comments exceeds the number displayed on one page, in our forum the "last post" link doesn't work :(

In other words: how to implement the number(s) of a page (I use the autopath modul).

with Kind Regards,
Steward

»


转自:http://www.cnblogs.com/linlu11/archive/2010/03/18/1689374

相关问答

更多

如何将论坛设置为vbulletin 5.2.0中的默认主页(How to set forum to the default main page in vbulletin 5.2.0)

你必须登录admincp,然后转到网站建设者,然后打开一个默认页面,点击保存选项首先你必须保存这个URL到另一个URL之后,打开你想要默认的URL并保存为主页的URL You have to login in admincp and then goto site builder then open a default page ,click on save option first you have to save this url to another url after that open u ...

重写我的BASE URL - Vbulletin(Rewriting my BASE URL - Vbulletin)

如果将apache与mod_rewrite一起使用,则可以在根目录中创建.htaccess文件 RewriteEngine on # Don't apply to URLs that go to existing files or folders. RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d # Only apply to URLs that aren't already under folde ...

Scrapy登录需要vBulletin指导(Scrapy login to vBulletin guidance needed)

您的登录数据发布到https://forums.chaosgroup.com/auth/login 如果您查看该页面的来源( scrape_home_page()中的scrape_home_page() ),您将看到以下内容: <div class="redirectMessage-wrapper"> <div id="redirectMessage">Logging in...</div> </div> <script type="text/javascript"> (fun ...

如何在迁移后将vBulletin帖子的URL请求映射到Drupal 7论坛评论?(How to map URL requests for vBulletin posts to Drupal 7 Forum comments after migration?)

我找到了解决方案。 Drupal Migrate在数据库中创建并保存表,将旧资源ID映射到新ID。 你必须要小心,因为vBulletin和Drupal论坛之间的架构是不同的; 主要是在D7中的论坛帖子(除了帖子中的第一篇帖子)不是节点,而是评论。 但我能够使用Join SQL查询来查找新的资源ID: mysql> SELECT m.sourceid1, m.destid1, c.cid, c.nid, c.subject FROM migrate_map_forum_posts m LEFT JO ...

我在哪里可以找到vBulletin中的external.php文件?(Where can I find external.php file in vBulletin?)

您可以在论坛文件夹的根目录中找到external.php。 例如: 如果您的论坛位于example.com/forums/或forums.example.com,那么您可以在/public_html/forums/external.php找到external.php。 或者,如果您的论坛位于域的根目录,那么您将在/public_html/external.php找到external.php。 正如其他人所说,我并不认为它对你想要达到的目标有多大用处。 You can find external.p ...

PHPBB登录脚本(PHPBB login script)

尝试使用ob_start(); 就在之后 例如<?php ob_start(); Try to use ob_start(); just after the e.g. <?php ob_start();

phpBB作为Oauth服务提供商(phpBB as a Oauth service provider)

phpBB身份验证是完全自包含的,所以这是不可能的。 phpBB authentication is fully self contained so this won't be possible.

用户评论最多来自Drupal + phpBB(Users with most comments from Drupal + phpBB)

你可以使用UNION: SELECT name, SUM(CommentCount) AS TotalCommentCount FROM ( SELECT U.name, COUNT(C.cid) AS CommentCount FROM dr_users AS U INNER JOIN dr_comments AS C ON U.uid = C.uid GROUP BY U.name UNION ALL SELECT U2.username AS name, COUN ...

phpBB manualy用SQL查询创建论坛帖子(phpBB manualy create forum posts with SQL query)

您使用的是哪个版本的PHPBB? 如果它比版本3更新,也许您可以使用其API来提交帖子。 这应该比直接将数据插入数据库要清晰得多。 以下是帖子提交API的链接: http : //wiki.phpbb.com/Function.submit_post 这是一个让您开始使用API的教程: http : //wiki.phpbb.com/Tutorial.Adding_pages Which version of PHPBB are you using? If it's newer than vers ...

如何使用BeautifulSoup获取vbulletin的最新帖子(How to get latest posts in vbulletin with BeautifulSoup)

当你获得title_rows时,你只得到一行而不是行。所以你可以使用下面的代码,根据你的要求返回15个结果。 import urllib from bs4 import BeautifulSoup url = 'http://ashiyane.org/forums/' connection = urllib.urlopen(url) data = connection.read() connection.close() # End the connection data_html = ...