Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.5 > vBulletin 3.5 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Latest Blog Feed in Postbit using Carp RSS Details »»
Latest Blog Feed in Postbit using Carp RSS
Version: 1.00, by nevetS nevetS is offline
Developer Last Online: Oct 2008 Show Printable Version Email this Page

Version: 3.5.0 Beta 3 Rating:
Released: 07-06-2005 Last Update: 07-06-2005 Installs: 34
Uses Plugins Template Edits
 
No support by the author.

I just posted this over at vbWebmaster Forums. I'm all excited because this is my first plugin and I know pretty much nothing about vbulletin. I got the idea from Shawn's forum at Digital Point

I just put this together for 3.5 using carp.

Step 1) Add a custom profile field for the RSS link. In my setup it was field5.
Step 2) Edit your postbit template as follows:
PHP Code:
<if condition="$post['field5']">
<
div class="smallfont">Recent Blog$blogentry</div>
        </if> 
Step 3) Create a new plugin. I named mine: Carp Configuration. Attach it to the "global_start" hook location.
Here is the code:
PHP Code:
require_once '/path/to/carp/carp.php';
CarpConf('cacheinterval',120);
/** You may want to set a cachepath specifically for your forum **/
CarpConf('cachepath','/where/you/want/your/cache/files/');
CarpConf('cacherelative',0);
/** You can omit the above two lines without a problem **/
CarpConf('cborder','');
CarpConf('poweredby','');
CarpConf('maxitems',1);
CarpConf('iorder','link'); 
Step 4) One more plugin. This one I called: Get Users Blog Entry
Attach this to hook location: postbit_display_start
PHP Code:
ob_start();
CarpCacheShow($post[field5]);
$blogentry ob_get_contents();
ob_end_clean(); 
That's it... away you go. If you don't have carp, you can check it out at: http://www.geckotribe.com/rss/carp/
I'm not sure if this will work with the free version, as I have the paid version.

I'm thinking about using grouper to set it up so I can parse atom files, but I don't know how important that will be.

Note: carp allows you to enter local paths and http paths for rss feeds. I've tried entering both in my user profile field successfully. You may want to disallow users from entering a local path just to be on the safe side. I don't have any code for that right now, but I'm sure there are some examples for field validation out there.

Carp has an option to store it's output in a variable ($carpoutput), but it didn't seem to work for me. That's why I used the ob_start and end_clean functions. If anybody has any feedback as to how this may be improved, I'm willing to listen.

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #42  
Old 05-13-2007, 03:03 PM
djbaxter djbaxter is offline
 
Join Date: Aug 2006
Location: Ottawa, Canada
Posts: 2,601
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

After upgrading to 3.66, my previous blog add-on needed to be redone. I decided to try this one instead, since frankly the previous one was a royal pain.

Works like a charm in 3.66 and seems to get Blogger feeds as well as other normal RSS feeds. Just set up the blogger feed URL as follows:

Code:
http://{blogname}.blogspot.com/feeds/posts/default?alt=rss
Of course, if your members encounter any difficulty getting their feeds to show up, you can always tell them to process it through Feedburner and use that URL.

I also couldn't get it to work with custom field paths but it's fine if you just delete those lines.

Thanks, nevetS!
Reply With Quote
  #43  
Old 05-21-2007, 06:50 PM
djbaxter djbaxter is offline
 
Join Date: Aug 2006
Location: Ottawa, Canada
Posts: 2,601
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Question:

Anyone know what I have to do to correct a blog title like the following:

Quote:
The sad state of Canada?s health care system
i.e., what do I have to do to get it to correctly parse or display "Canada's" instead of "Canada?s"?
Reply With Quote
  #44  
Old 05-24-2007, 03:18 PM
wtricks's Avatar
wtricks wtricks is offline
 
Join Date: Aug 2006
Posts: 109
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
You did not enter the correct format for the My latest blog entry field. Please read the field description for the expected format.
What's the format it expects? I tried my link from feedburner, the link of the rss feed as it appears in the footer of my wordpress blog .. nothing. Thank you in advance
Reply With Quote
  #45  
Old 05-24-2007, 03:50 PM
djbaxter djbaxter is offline
 
Join Date: Aug 2006
Location: Ottawa, Canada
Posts: 2,601
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I don't use Feedburner but for WordPress it should look like http://www.somenlog.com/feed/
Reply With Quote
  #46  
Old 06-07-2007, 03:34 PM
wtricks's Avatar
wtricks wtricks is offline
 
Join Date: Aug 2006
Posts: 109
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I used this and 3 other possible links with no use. Here is the code as I have put it in the plugin section. I might have not set the path correctly I assume.

Code:
require_once 'carp/carp.php';
CarpConf('cacheinterval',120);
/** You may want to set a cachepath specifically for your forum **/
CarpConf('cachepath','carp/');
CarpConf('cacherelative',0);
/** You can omit the above two lines without a problem **/
CarpConf('cborder','');
CarpConf('poweredby','');
CarpConf('maxitems',1);
CarpConf('iorder','link');
I have the carp folder in : wtricks.com/forums/carp and the cache folder is in wtricks.com/forums/carp/cache ...

Thank you again for any possible tips as how to solve this
Reply With Quote
  #47  
Old 06-20-2007, 10:05 AM
Retal Retal is offline
 
Join Date: Nov 2006
Posts: 58
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I will pay 15 bucks via PayPal to the person who will make an installable and working product for vB 3.6.x from this one. If someone is interested, please PM me
Reply With Quote
  #48  
Old 06-28-2007, 01:16 PM
Snider Snider is offline
 
Join Date: May 2007
Posts: 25
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I don't even get an error - it just shows the Blog: and no link or text at all.

Any ideas ?


http://www.widewebtalk.com/showthrea...=1861#post1861
Reply With Quote
  #49  
Old 06-28-2007, 01:24 PM
djbaxter djbaxter is offline
 
Join Date: Aug 2006
Location: Ottawa, Canada
Posts: 2,601
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Snider View Post
I don't even get an error - it just shows the Blog: and no link or text at all.

Any ideas ?

http://www.widewebtalk.com/showthrea...=1861#post1861
Did you create and run the cron job ("scheduled task") to update the feeds?
Reply With Quote
  #50  
Old 06-28-2007, 01:28 PM
Snider Snider is offline
 
Join Date: May 2007
Posts: 25
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

No I have not as that is not in the instructions to do that I can find.
Reply With Quote
  #51  
Old 06-28-2007, 01:41 PM
djbaxter djbaxter is offline
 
Join Date: Aug 2006
Location: Ottawa, Canada
Posts: 2,601
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

My aplologies - you're correct. That was for another add-on I tried that didn't work properly for me.

If I recall correctly, I had to fiddle with this a bit to get it to work.

Make sure that your Carp Configuration plugin looks like this:

Code:
require_once '/full/server/path/to/forum/carp/carp.php';
CarpConf('cacheinterval',120);
CarpConf('cborder','');
CarpConf('poweredby','');
CarpConf('maxitems',1);
CarpConf('iorder','link');
CarpConf('linktarget',1);
And that your Get Users Blog Entry plugin looks like this:

Code:
ob_start();
CarpCacheShow($post[field6]);
$blogentry = ob_get_contents();
ob_end_clean();
Then double check that the correct field is identified in the edits to your postbit:

Code:
<if condition="$post['field6']">
<div class="smallfont">Recent Blog: $blogentry</div>
</if>
In the supplied example, it is field5. For my forum it was field6. It may be different for you forum.
Reply With Quote
Reply


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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 12:11 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05608 seconds
  • Memory Usage 2,327KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (5)bbcode_code
  • (3)bbcode_php
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete