vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Truncate RSS Feed Manager posts? (https://vborg.vbsupport.ru/showthread.php?t=213977)

lingstar 05-18-2009 12:59 PM

Truncate RSS Feed Manager posts?
 
Hello,

I have set my RSS feed manager to publish snippets of my blog. Thing is, it publishes the entire content of the blog post and not the first 150 characters or so.

Is there a way I can set in the RSS Feed manager a parameter to truncate the post to the first 150 characters? I'd like to do it in the RSS feed manager instead of in my blog in case other users want their content posted as well.

Thanks!

Barbara

Lynne 05-18-2009 02:26 PM

I don't know about for blogs, but this works for the regular RSS feed and I'm sure you can modify it to work with the blog feed:

hook location: external_query
PHP Code:

unset($vbulletin->GPC['fulldesc']); 
$vbulletin->options['threadpreview'] = 150
$hook_query_fields .= ",LEFT(post.pagetext,300) AS message"


lingstar 05-18-2009 03:04 PM

Quote:

Originally Posted by Lynne (Post 1812943)
I don't know about for blogs, but this works for the regular RSS feed and I'm sure you can modify it to work with the blog feed:

hook location: external_query
PHP Code:

unset($vbulletin->GPC['fulldesc']); 
$vbulletin->options['threadpreview'] = 150
$hook_query_fields .= ",LEFT(post.pagetext,300) AS message"


Forgive me for the following inane question -

What do I *do* with that code snippet? Is there a specific area in AdminCP where I should enter it?

Thank you,

Barbara

Lynne 05-18-2009 03:17 PM

It's a plugin. I can't help you with what hook location to use or how to modify the code since I don't have the blog software.


All times are GMT. The time now is 05:31 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01030 seconds
  • Memory Usage 1,724KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (4)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete