Register Members List Search Today's Posts Mark Forums Read

Reply
 
Mod Options
Display latest blog post in postbit using Magpie RSS Details »»
Display latest blog post in postbit using Magpie RSS
Mod Version: 1.10, by pmkb (Contributor) pmkb is offline
Developer Last Online: Nov 2013 I like it Show Printable Version Email this Page

vB Version: 3.6.8 Rating: (3 votes - 4.67 average) Installs: 23
Released: 27 Aug 2007 Last Update: 29 Aug 2007 Downloads: 142
Not Supported Uses Plugins Template Edits Is in Beta Stage  

This mod borrows extensively from the work vauge did for vB 3.5 (as found here) and from the work nevetS did for a similar mod using CaRP RSS.

I did PM vauge requesting permission to update his mod as many people were having difficulty implementing it, but s/he hasn't been online in several months and didn't respond to my PM for over a week now, so I decided to go ahead and post the mod.

This mod will allow forum members to add their blog's RSS feed URLs to their profile and have the forum display a link to their latest blog post next to their username every time they post in the forum.

I had been using nevetS's CaRP mod for this for a long time, but the Magpie RSS reader is actually more powerful (can parse Atom feeds too) and flexible. Also, I don't know if anyone can find the free download for CaRP anymore.

Installation:
  1. Download Magpie RSS and install on your server. Magpie is a free, open source RSS reader with caching. It consists of 4 .php files plus one external library file. I recommend you create a directory called magpie in your domain's root directory and upload the files there.

    Be sure when installing to create a cache sub-directory inside the magpie directory and CHMOD it to 777.
  2. In your vB ACP, add a new user profile field. I used the following:
    Title: Blog Feed
    Description: Do you write a blog? Post the RSS/XML feed for the blog here and a link to your latest blog post will show in the forums next to your name with every post.
    Max Length: 200
    Type: Single Line
    Required: No
    Editable: Yes
    Private: No * Must be No if you want guests and registered members to see the blog links
    Searchable/Shown on memberlist: No
    After saving, go to the User Profile Field Manager and note what the Name column displays for your new field. It should be field5 or field6 or something like that.
  3. Open the attached magpierss.xml file in your favorite text editor and modify the paths for the MAGPIE_DIR and MAGPIE_CACHE_DIR variables to match your server's directory structure. You can adjust the value for the MAGPIE_CACHE_AGE if you like. It's set to update the cache every 4 hours by default. Last, update the field5 to your field # in two places in the postbit_display_start section. Save the file.
  4. Import your updated magpierss.xml file using the Add/Import Product link in the Manage Products page.
  5. Edit your postbit template. Find $template_hook[postbit_userinfo_left] and add just before it:
    <if condition="$post['field5']"><div class="smallfont">Recent Blog: <a href="$blogLink" target="_blank">$blogTitle</a></div></if>
    You should change the field # in that code to match your field # of course. You can also add rel="nofollow" to the link code if you are so inclined.

That's it.

P.S. Updated per Marco van Herwaarden's suggestions for better performance and security.

P.P.S. If anyone knows how to fix the XML file so that it injects the template code into the postbit_userinfo_left hook so folks don't have to make a manual template edit, by all means please share.

P.P.P.S Unfortunately, there appears to be a conflict with the magpie code and vBulletin's AJAX code which is beyond my coding skills to fix. See page two of this thread for more details.

Download Now

Only licensed members can download files, Click Here for more information.

Screenshots

Click image for larger version

Name:	blogpost.gif
Views:	859
Size:	3.6 KB
ID:	69147

Show Your Support

  • To receive notifications regarding updates -> Click to Mark as Installed.
  • If you like this modification support the author by donating.
  • This modification may not be copied, reproduced or published elsewhere without author's permission.
Similar Mod
Mod Developer Type Replies Last Post
Latest Blog Feed in Postbit using Carp RSS nevetS vBulletin 3.5 Add-ons 81 15 Apr 2009 11:53
Latest blog in postbit - magpierss vauge vBulletin 3.5 Add-ons 26 28 Sep 2007 17:05

Comments
  #2  
Old 27 Aug 2007, 16:08
Ratman2050 Ratman2050 is offline
 
Join Date: Jul 2007
Reserved.

P.S. My First Reserve
Reply With Quote
  #3  
Old 27 Aug 2007, 18:39
yahoooh yahoooh is offline
 
Join Date: Oct 2002
any demo?
Reply With Quote
  #4  
Old 27 Aug 2007, 19:31
pmkb's Avatar
pmkb pmkb is offline
 
Join Date: Sep 2005
I added a screenshot.
Reply With Quote
  #5  
Old 28 Aug 2007, 13:38
Hornstar's Avatar
Hornstar Hornstar is offline
 
Join Date: Jun 2005
Real name: Matt
When I read the title of this mod, I thought vb must have released its blog ^^ but then I got my hopes up too fast lol. nice mod tho.
Reply With Quote
  #6  
Old 28 Aug 2007, 15:32
pmkb's Avatar
pmkb pmkb is offline
 
Join Date: Sep 2005
Sorry about that! It's hard to describe some mods in just a few words.
Reply With Quote
  #7  
Old 29 Aug 2007, 09:40
Triky's Avatar
Triky Triky is offline
 
Join Date: Mar 2007
Location: [Italy]
Installed.
I will use this feature in the future.
Really thanks, pmkb.
__________________
I'm italian, I am learning english.. so, please, if you see any errors in my grammar or spelling, let me know via PM. Danke!

vB-Italy.org - Italian vBulletin Support Forum
Reply With Quote
  #8  
Old 29 Aug 2007, 09:56
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Is the magpie rss_fetch.inc file needed on each vBulletin page? You are currently loading it unconditionally in the "global_start" hook. This might lead to more overhead then needed.


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

As you overwrite $blogTitle and $blogLink each time you go thru the loop, only the last value will ever be displayed (assuming you can have more then 1 entry, otherwise the loop does also not make sense).
__________________
Marco van Herwaarden
Ex vBulletin.org Coordinator

Last edited by Marco van Herwaarden : 29 Aug 2007 at 10:19.
Reply With Quote
  #9  
Old 29 Aug 2007, 10:09
gforce75 gforce75 is offline
 
Join Date: Sep 2003
Good catch Herwaarden. Nice mod, but will wait till see a demo
Reply With Quote
  #10  
Old 29 Aug 2007, 12:04
pmkb's Avatar
pmkb pmkb is offline
 
Join Date: Sep 2005
gforce, what do you mean by a demo? I posted a screenshot of what it does from my own forum (see sig) where this mod is working. I have the mod installed on 3 forums and it works great.

Last edited by pmkb : 29 Aug 2007 at 12:48.
Reply With Quote
  #11  
Old 29 Aug 2007, 12:42
pmkb's Avatar
pmkb pmkb is offline
 
Join Date: Sep 2005
OK. I've updated the plugin per Marco van Herwaarden's suggestions to improve performance and security.
Reply With Quote
  #12  
Old 29 Aug 2007, 20:07
FreshFroot's Avatar
FreshFroot FreshFroot is offline
 
Join Date: Aug 2005
Originally Posted by hornstar1337 View Post
When I read the title of this mod, I thought vb must have released its blog ^^ but then I got my hopes up too fast lol. nice mod tho.
umm vb just released vblog right now
Reply With Quote
  #13  
Old 29 Aug 2007, 23:58
Michael2's Avatar
Michael2 Michael2 is offline
 
Join Date: Nov 2001
Will this work with the vBulletin blog or is there an easier way to set this up? I'd rather it be done automatically and not have users be responsible for adding their RSS feed (which most probably won't do).
Reply With Quote
  #14  
Old 30 Aug 2007, 02:15
pmkb's Avatar
pmkb pmkb is offline
 
Join Date: Sep 2005
This was designed to let users who have their own blogs on their own sites display the latest blog post by their name. From what I saw of the vB Blog announcment, it offers RSS feeds, so it could be used to display the latest vB Blog post, but users would need to put the blog feed URL in their profile.

I imagine that vB will update their vB Blog at some point to include this feature, but as far as I can tell, right now it just shows a number indicating the number of blog posts instead of a title/link to the latest post.
Reply With Quote
  #15  
Old 30 Aug 2007, 17:01
XManuX XManuX is offline
 
Join Date: Feb 2007
Any ideas why only admins on my boards can view the "My Blog:" infos ? Any other usergroups can't !
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
Mod Options

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
Forum Jump


New To Site? Need Help?

All times are GMT. The time now is 02:01.

Layout Options | Width: Wide Color: