Customizing SMF > Modifications and Packages

RSS Feed Poster 3.0.4 Released with 2.0 Support!

<< < (517/547) > >>

MrWizard:
How to get it to remove or otherwise convert the embedded HTML inside the RSS feed to either bb code (where applicable) or remove all together ?

The "enable html" doesn't appear to do much except catch the title.  enabling/disabling "simple html" inside the forum also makes little difference.


  Feed URL : http://news.google.com/news?hl=en&tok=cEAjN617gdb8iQC1aT4ffg&ds=n&pq=%22murphy+texas%22&cp=8&gs_id=ie&xhr=t&q=%22murphy,+texas%22&safe=off&gl=us&bav=on.2,or.r_gc.r_pw.r_cp.r_qf.&biw=1482&bih=949&um=1&ie=UTF-8&output=rss 

   Posting looks like : <table border="0" cellpadding="2" cellspacing="7" style="vertical-align:top;"><tr><td width="80" align="center" valign="top"><font style="font-size:85%;font-family:arial,sans-serif"></font></td><td valign="top" class="j"><font style="font-size:85%;font-family:arial,sans-serif"><br /><div style="padding-top:0.8em;"><img alt="" height="1" width="1" /></div><div class="lh"><a href="http://news.google.com/news/url?sa=t&amp;fd=R&amp;usg=AFQjCNEhNUYxwH_VsfjxDPdwMICQFBoXOw&amp;url=http://www.cantonrep.com/life/weddings/x1062477557/Peirce-Fromholtz-wedding"><b>Peirce-Fromholtz wedding</b></a><br /><font size="-1"><b><font color="#6f6f6f">Canton Repository</font></b></font><br /><font size="-1">They reside in <b>Murphy, Texas</b>. Rachel Peirce of Katy, Texas and Kyle Fromholtz of North Canton, Ohio were married April 21, 2012 at The Milestone in Denton, Texas by the Rev. Randy Prouse. Parents of the bride are James and Nancy Peirce of Katy, Texas.</font><br /><font size="-1" class="p"></font><br /><font class="p" size="-1"><a class="p" href="http://news.google.com/news/more?gl=us&amp;pz=1&amp;ned=us&amp;ncl=dZx6dHmB56URzvM"><nobr><b></b></nobr></a></font></div></font></td></tr></table>

chuck23322:
MrWiz -- I don't think the RSS Feed Poster is that "intelligent" to make conversions from HTML -> BB code, etc.   It's there to simply take the feed and post it.  If it has HTML embedded in the "description" field, it posts it too.   

You would likely need to see if the "feed" can be adjusted so that it outputs plain text instead {if that vendor offers it}....

Or you may be able to use "Yahoo Pipes" to do some conversions on the feed using RegEx -- I use Yahoo Pipes to do some work on my feeds -- but the scope of assisting with Yahoo Pipes is beyond what I can offer here.

Something like (on Yahoo Pipes) - Fetch Feed -> loop w/ regex against desc field to remove html -> Create Rss -> output pipe

http://networking.ringofsaturn.com/Web/removetags.php
http://www.pagecolumn.com/tool/all_about_html_tags.htm

Or you can search the Yahoo Pipes to see if somebody else has already created a pipe to remove HTML that you can modify/customize...

Perhaps somebody has a better answer.   I tend to use Yahoo Pipes to be a brute-force tool since I'm needing to create RSS feeds from web pages, etc that don't provide RSS...

~Note:  The Yahoo Pipes generates a RSS link that has special characters in it, and the feed poster doesn't like the link.  For each of my Yahoo Pipes RSS feeds I use, I've created a "tinyurl.com" version of the Yahoo Pipes RSS link and that works fine.

MrWizard:
After looking at the code, I am thinking a simple patch for this should work ..  In the file Subs_RSS.php

Adding html_entity_decode() and strip_tags() to fix up the variable $rssdata at the end should clean it up ..

   

   // Remove stupid headers.


   do


{


$header .= fgets ($fp, 128 );

 } while ( strpos($header, "\r\n\r\n" ) === false );

   while (!feof($fp))

   

   {

       $rssdata .= fgets($fp, 128);

   }

   fclose($fp);




   // Get rid of the stupid header information! Wish the function did it for me.

   
   @$finalrss = $rssdata;


}

}

avguste:
Just installed this, but cant figure how to get it to work.
Could someone post how to setup a cron job?

Also, when I go to the cronrss url ( http://political.antonovconsulting.com/cronrss.php ), I get an internal error

Thank you

chuck23322:

--- Quote from: avguste on August 10, 2012, 08:00:20 PM ---Just installed this, but cant figure how to get it to work.
Could someone post how to setup a cron job?

Also, when I go to the cronrss url ( http://political.antonovconsulting.com/cronrss.php ), I get an internal error

Thank you

--- End quote ---

Until you get the manual "cronrss.php" running -- the setting up a cron job won't work.

There's dozens of posts in this thread about the varying options available for a cron job.

But your first step needs to be getting the "cronrss.php" to return the "Feed Poster Configuration" answer (and see your first feed item posted)

Much later -- then you worry about whether to use cron, fake cron, or scheduled tasks.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version