Welcome, Registration, and other StartingPoints; Foswiki history & Wiki style; All the docs...
Edit | Attach | New | Raw | Delete | History | Print | Tools
You are here: System » HeadlinesPlugin

Headlines Plugin

Description

This plugin displays RSS and ATOM feeds from news sites. Use it to build news portals that show headline news.

Note: Syndic8.com ( http://www.syndic8.com/ ) is a good site listing many RSS feeds.

Syntax Rules

%HEADLINES{"..."}%

Parameter ExplanationSorted ascending Default
href="..." (Alternative to above) N/A
format Format of one item. Can include these variables:
- $title: news item title (item.title)
- $link: news item link (item.link)
- $description: news item description (item.description)
- $date: the publication date (item.pubDate, item.date)
- $category: the article category (item.category)
Global FORMAT setting
header Header. Can include these variables: - $channeltitle, $title: title of channel (channel.title)
- $channellink, $link: link of channel (channel.link)
- $channeldescription, $description: description (channel.description)
- $channeldate, $date: publication date of the channel (channel.pubDate)
- $rights: copyrights of the channel (channel.copyright)
- $imagetitle: title text for site (image.title)
- $imagelink: link for site (image.link)
- $imageurl: URL of image (image.url)
- $imagedescription: description of image (image.description)
Global HEADER setting
limit="12" Maximum number of items shown Global LIMIT setting
refresh="60" Refresh rate in minutes for caching feed; "0" for no caching Global REFRESH setting
"..." source of RSS feed; this can be an url (starting with http) or a web.topic location for internal feeds None; is required

The header and format parameters might also use variables rendering the dc, image and content namespace information. Note, that only bits of interest have been implemented so far and those namespaces might not be implemented fully yet.

Rendering the dc namespace

The following variables are extracting the dc namespace info, that could be used in header and format. Nnote, that some of the variables are already used above. This is done by purpose to use different feeds with the same formating parameters. If there's a conflict the non-dc tags have higher precedence, i.e. a <title> content </title> is prefered over <dc:title> content </dc:title> .

  • $title: channel/article title (dc:title)
  • $creator: channel creator (dc:creator)
  • $subject: subject text; this will also add an image according to the subject hash list, see above (dc:subject)
  • $description: ... (dc:description)
  • $publisher: the channel/article publisher (dc:publisher)
  • $contributor: ... (dc:contributor)
  • $date: ... (dc:date)
  • $type: ... (dc:type)
  • $format: ... (dc:format)
  • $identifier: ... (dc:identifier)
  • $source: ... (dc:source)
  • $language: ... (dc:language)
  • $relation: ... (dc:relation)
  • $coverage: ... (dc: coverage)
  • $rights: ... (dc: rights)

Rendering the image namespace

An image:item is converted into an <img> tag using the following mappings:

  • src: image url (rdf:about attribute of the image.item tag)
  • alt: image title (title)
  • width: image width (image:width)
  • height: image height image:height)

Rendering the content namespace

The variable $content is refering to the <content:encoding> content </content:encoding>.

Examples

Slashdot News

Write

%HEADLINES{"http://slashdot.org/slashdot.rdf" header="---+!! [[$link][$title]]$n $description" format="$t* [[$link][$title]]"}%
to get the latest Slashdot news as a bullet list format:

Business Opportunities Weblog

Write

%HEADLINES{"http://www.business-opportunities.biz/feed" limit="3"}%

to get the latest postings on the "Business Opportunities" weblog:

Tue, 02 Jun 2015 23:57:15 +0000
The original blog about business opportunities and business ideas for small business entrepreneurs
Tue, 02 Jun 2015 21:21:11 +0000 Erin Eagan

When you think of a franchise, most likely you're going to find yourself thinking of one of the top fast food franchises. While, depending upon your dietary habits, you may be inclined to look down upon on fast food franchises, you'd be letting your stomach do the talking when your entrepreneurial brain should be doing the thinking.

Many fast-food restaurants are incredibly lucrative franchise business opportunities. If you knew what the earning potential of some of these fast food restaurants are, you might not be so inclined to look down your nose at them.

RELATED: TOP FRANCHISES OF 2015

If you’re looking for a franchise, you want a top performer. We’ve compiled a list of some of the best fast food franchises in operation today.

Chick-fil-A

Although Chick-fil-A has received some negative press due to its foray into the world of social issues, business for Chick-fil-A franchises has never been better. According to Forbes, a Chick-fil-A franchise rakes in an average of approximately $3 million every year. Now, that's something to cluck about!

McDonald's

The terms ''franchise'' and ''McDonald's'' are practically synonymous with one another, and it's still the general consensus that a McDonald's is the Cadillac of franchise opportunities. The startup costs for such a franchise vary greatly depending upon the region and location, but the profits are all but guaranteed. An average McDonald's franchise pulls in about $2.6 million a year.

Jason's Deli

With a presence in only 28 states, it's possible that you've never heard of Jason's Deli. But that doesn't mean it's not a lucrative franchise opportunity for you, provided you're in the right area of the country. Forbes estimates that an average Jason's Deli fast food franchise earns about $2.5 million each year.

Krispy Kreme

If you've never eaten a Krispy Kreme doughnut, then you're missing out. This delicious purveyor of glazed and filled doughnuts and coffee is extremely popular with those that have had the opportunity to sample its offerings. If you've been considering a doughnut franchise, then maybe the $2.4 million annual sales of a Krispy Kreme franchise will sweeten the pot.

Panera Bread

With people becoming more and more health-conscious by the day, Panera Bread has emerged as a healthier alternative to other fast food chains. This has caused the deli-style chain to explode in popularity since it was founded in 1981, with 1,652 locations worldwide. On average, a Panera Bread franchise does about $2.4 million in sales every year.

Chipotle

This purveyor of burritos and tacos with responsibly sourced ingredients has been winning over more members of the public every year. Starting in 1993, this business has expanded out to 1,410 total locations. Business is good, too, as an average Chipotle location manages to do approximately $2.1 million in sales each and every year.

Whataburger

With around 730 locations throughout the southern U.S., Whataburger is extremely popular with the burgers and fries dining crowd. Started in 1950, this company also has a long-standing reputation for putting out quality product. That's why a Whataburger franchise performs so well. Forbes estimates that an average Whataburger franchise is able to do $2 million in sales a year which is why it makes our list of the top fast food franchises.

In-N-Out Burger

Speaking of burgers, here's a fast food franchise that has a national following of dedicated customers, even though its franchises are only based in the southwest U.S. It's flagship (and off-menu) offering is the Double-Double Animal Style, which haunts burger-lovers in their dreams. One of these immensely popular franchises can rake in $1.9 million a year on average.

RELATED: BEST BURGER FRANCHISES

Culver's

Operating primarily in the Midwest, Culver's is a popular purveyor of ButterBurgers and frozen custard. There are currently 472 Culver's franchises in operation. Even though its reach is smaller than other franchises, its sales are just as good. An average Culver's franchise can expect to do approximately $1.8 million in sales each year.

Zaxby's

Much like Chick-fil-A, this franchise is concentrated primarily in the southern US and is a purveyor of bone-lickin' good chicken. Only in operation since 1990, the up-and-coming franchise has approximately 600 locations currently in operation. One of these Zaxby's franchises can expect to see annual sales in the neighborhood of $1.75 million.

Bojangle's Famous Chicken 'n Biscuits

If you want to know what this franchise is in the business of selling, then just take a look at its name. Like Zaxby's, these franchises are primarily located in the southeastern U.S. Forbes estimates that an average Bojangle's franchise can do approximately $1.7 million in sales annually.

Steak 'n Shake

Headquartered in San Antonio, Tex., this business operates as a hybrid of a sit-down style diner restaurant and a fast food restaurant. With approximately 100 franchised locations, a franchisee of Steak 'n Shake can expect to do sales of $1.7 million annually.

Tue, 02 Jun 2015 18:45:31 +0000 Erin Eagan

Great beer is easy to come by, but it's either mass-produced on the supermarket shelves or overpriced at local brew pubs.

And making your own? That's another story. Beer enthusiasts love home brewing, but the process of making beer - until now - has been laborious and complicated.

RELATED: IS A HOME-BASED BUSINESS RIGHT FOR YOU?

Home brewing requires specialized equipment, a tight schedule, strict temperature control and extensive knowledge to brew even the most basic beer. Stouts, IPAs and others? Unless you're an expert, good luck with that.

So therein lies the problem. You want to enjoy a premium home-brewed craft beer without all the hassle. Now you can with Brewie, the world's first fully automated brewing machine. Brewie is revolutionizing the making of craft beers.

With the Brewie, brewing beer is that's-step process is remarkably simple:

1. Put a pad in your Brewie - Each pad contains everything you need to brew your own beer. Water input can be measured both automatically and manually.

2. Scan the RFID card - Each Brewie pad comes with and RFID card that contains the details of your recipe. Place the card in front of the wireless RFID reader and Brewie does the rest. Just press start.

3. Let it brew - After 5-6 hours of cooking and 5-14 days of fermenting, your beer is ready.

RELATED: THIS BEER MAKES YOU A BETTER ENTREPRENEUR

With the Brewie app, you can monitor the whole process and stay informed on your brew's real-time progress. You get an alert when its finished.

To order your very own Brewie, click here.

Tue, 02 Jun 2015 14:35:34 +0000 Erin Eagan

Who doesn't love popcorn? Well, as it turns out, this classic snack may actually not be the healthiest. Fortunately, you don't have to go without your fix thanks to Jen and Jeff Martin. The founders of Pipcorn entered the Shark Tank last year on November 17 and walked out as winners. Here are five quick facts you should know about their company.

The Founders Are Family

Though people are often warned about going into business with their family, the Martins prove that some siblings make the best partners. The idea actually came from Jen's time working in a health food store. One day, a farmer introduced her to a hull-less kernel of popcorn. She got her brother to pop it and both savored the flavor of how this new type of corn tasted.

Fortunately, the two are incredibly close and love working with one another. In fact, it seems to have helped their business grow.

They Went with Barbara

If you saw the episode, you know they originally asked for $200,000 in exchange for 10 percent of their company. After tasting the product, the sharks became hungry for a deal. Robert said he'd give them their amount, but wanted double the equity. Barbara countered by offering them the full price, but with a contingency: they had to take out $900 every week. After that, Robert tried going back to the original deal, but it was too late. They decided on working with Barbara.

The brother and sister gushed about how helpful Barbara had been, due to both her proximity and her experience with food in the past. More than anything, she taught them to be themselves.

Pipcorn Is Vegan and Gluten-Free

Pipcorn, which is about half the size of traditional popcorn, is made using olive oil. No butter is ever added. The product is also vegan and gluten-free, with no GMOs used at any time. The corn comes from whole grains.

Pipcorn Has One Huge Advantage

There are a number of reasons to love Pipcorn. However, you can't beat the fact that this version of popcorn won't get stuck in your teeth. Basically, the hulls of the kernels used to make Pipcorn are too delicate. The shell of each piece breaks up into tinier pieces making them easier to digest as well.

They Have a Pretty Powerful Fan

After appearing on Shark Tank, the sister and brother team took their company from Brooklyn and moved to Manhattan, so they could begin an operation that would meet their growing demand.

While countless people have tried and fallen in love with Pipcorn, one fan is especially impressive: Oprah. Except the media queen was a fan long before the snack showed up on Shark Tank. After just a month in business, Oprah mentioned them as one of her favorite things. This was back in 2012, which just goes to show that Oprah has always been ahead of a trend.

From one simple kernel came an idea that may soon be worth millions. Keep that in mind the next time you think a business idea is too small to become something big.

Plugin Settings

Plugin settings are stored as preferences variables. To reference a plugin setting write %<plugin>_<setting>%, for example, %HEADLINESPLUGIN_SHORTDESCRIPTION%. Note: Don't modify the settings here; copy and customize the settings in SitePreferences. For example, to customize the USERAGENTNAME setting, create a HEADLINESPLUGIN_USERAGENTNAME setting in Main.SitePreferences.

  • One line description, shown in the TextFormattingRules topic:
    • Set SHORTDESCRIPTION = Show headline news in Foswiki pages based on RSS and ATOM news feeds from external sites

  • Refresh rate in minutes for cached feeds. Disable caching: 0, default: 60
    • Set REFRESH = 60

  • Maximum number of items shown. Default: 100
    • Set LIMIT = 100

  • Use LWP::UserAgent, or fallback to Foswiki's internal getUrl() method. Default: yes
    • Set USELWPUSERAGENT = yes

  • Timeout fetching a feed using the LWP::UserAgent. Default: 20
    • Set USERAGENTTIMEOUT = 20

  • Name of user agent. Default: FoswikiHeadlinesPlugin/2.21.1
      * Set USERAGENTNAME = FoswikiHeadlinesPlugin/2.21.1

  • Default header: (variables are explained in the syntax rules)
      * Set HEADER = <div class="headlinesChannel"><div class="headlinesLogo"><img src="$imageurl" alt="$imagetitle" border="0" />%BR%</div><div class="headlinesTitle">$n---+!! <a href="$link">$title</a></div><div class="headlinesDate">$date</div><div class="headlinesDescription">$description</div><div class="headlinesRight">$rights</div></div>

  • Default format of one item: (variables are explained in the syntax rules)
      * Set FORMAT = <div class="headlinesArticle"><div class="headlinesTitle"><a href="$link">$title</a></div>$n<span class="headlinesDate">$date</span> <span class="headlinesCreator"> $creator</span> <span class="headlinesSubject"> $subject </span>$n<div class="headlinesText"> $description</div></div>

  • Values taken from configure: (only supported if CPAN:LWP is installed)
    • $Foswiki::cfg{PROXY}{HOST} - proxy host, such as "proxy.example.com";
    • $Foswiki::cfg{PROXY}{PORT} - proxy port, such as "8080";
    • $Foswiki::cfg{PROXY}{SkipProxyForDomains} - domains excluded from proxy, such as "intra.example.com, bugs.example.com";

Style sheets

The default HEADER and FORMAT settings use the following styles. See the style.css file defining the default CSS properties (indentation illustrates enclosure).

  • headlinesRss: output of the HeadlinesPlugin (div)
    • headlinesChannel: channel header (div)
      • headlinesLogo: channel logo (div)
      • headlinesTitle: channel title (div)
      • headlinesDate: channel date (div)
      • headlinesDescription: channel description (div)
      • headlinesRight: channel copyright (div)
    • headlinesArticle: one news item (div)
      • headlinesTitle: article title (div)
      • headlinesDate: article date (span)
      • headlinesCreator: author of article (span)
      • headlinesSubject: subect category of the article (span)
      • headlinesText: article text (div)

Plugin Installation Instructions

  • Download the ZIP file
  • Unzip it in your foswiki installation directory. Content:
    File: Description:
    data/System/HeadlinesPlugin.txt plugin topic
    pub/System/HeadlinesPlugin/style.css default css
    lib/Foswiki/HeadlinesPlugin.pm plugin perl module
    lib/Foswiki/HeadlinesPlugin/Core.pm plugin core
    Check if above examples show a news feed instead of variable.
  • Optionally, run HeadlinesPlugin_installer.pl to automatically check and install other Foswiki modules that this module depends on. You can also do this step manually.
  • Alternatively, manually make sure the dependencies listed in the table below are resolved.
    NameVersionDescription
    Digest::MD5>=2.33Required. Download from CPAN:Digest::MD5
    LWP::UserAgent>=5.803Optional. Download from CPAN:LWP::UserAgent

Plugin Info

Plugin Author: TWiki:Main.PeterThoeny, Foswiki:Main.MichaelDaum (2005-2007)
Copyright: © 2002-2009, Peter Thoeny, TWIKI.NET; 2005-2007, Michael Daum http://wikiring.de
License: GPL (GNU General Public License)
Plugin Version: 2.21.1 (08 Mar 2009)
Change History:  
08 Mar 2009: Ported without changes to Foswiki namespace by Kenneth Lavrsen and put under "Feel Free To Modify" in Foswiki context.
12 Feb 2009: {PROXY}{HOST} supports domain with and without protocol -- Peter Thoeny
06 Feb 2009: added {PROXY}{SkipProxyForDomains} configure setting, added USERAGENTNAME plugin setting -- Peter Thoeny
11 Dec 2008: added {PROXY}{HOST} and {PROXY}{PORT} configure settings -- Peter Thoeny
13 Sep 2007: fixed parsing of content:encoded
23 Jul 2006: improved atom parser; if a posting has no title default to 'Untitled'
26 Apr 2006: added lazy compilation
10 Feb 2006: packaged using the TWiki:Plugins/BuildContrib; minor fixes
03 Feb 2006: off-by-one: limit="n" returned n+1 articles; make FORMAT and HEADER format strings more robust
23 Jan 2006: released v2.00
05 Dec 2005: internal feed urls must be absolute
02 Dec 2005: added web.topic shorthand for internal feeds
29 Nov 2005: fixed CDATA handling
21 Nov 2005: added ATOM support; extended RSS support; added dublin core support; added content support; optionally using LWP to fetch feeds to follow redirections; corrected CPAN dependencies ; recoding special chars from html integer to entity encoding to increase browser compatibility; added css support; use getWorkArea() if available
11 May 2005: TWiki:Main.WillNorris: added DevelopBranch compatability
31 Oct 2004: Fixed taint issue by TWiki:Main.AdrianWeiler; small performance improvement
29 Oct 2004: Fixed issue of external caching if mod_perl or SpeedyCGI is used
02 Aug 2002: Implemented caching of feeds, thanks to TWiki:Main/RobDuarte
11 Jun 2002: Initial version (V1.000)
Perl Version: 5.008
Plugin Home: http://foswiki.org/Extensions/HeadlinesPlugin
Feedback: http://foswiki.org/Extensions/HeadlinesPluginDev
spacer
Copyright © 2015 Atomikos BVBA. Transaction Management for Extreme Transaction Processing and SOA Environments serving ISV, Commercial, OEM and Open Source Markets
Site map RSS ATOM