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 Explanation DefaultSorted ascending
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
href="..." (Alternative to above) N/A
"..." 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:

Wed, 03 Jun 2015 14:06:05 +0000
The original blog about business opportunities and business ideas for small business entrepreneurs
Wed, 03 Jun 2015 14:06:05 +0000 Erin Eagan

By now, you've probably heard a million times how important social media is for your business. Well, there's definitely no doubting that social media can make a huge difference for your company. If you ignore it, your competitors can use it to bury you - and you can’t, or shouldn’t, let that happen. So if you haven't been giving social media the credit it deserves, the following tips are worth considering.

Be Personable

Unless you own a Fortune 500 company, one of your biggest marketing advantages is that you can show customers the ''real you.'' Larger companies usually can't get away with this tactic. It comes off as false or insincere. Owning a small- or medium-sized business doesn't involve this challenge, though. Social media is also the perfect tool for doing this.

RELATED: 5 TECHNOLOGY TIPS EVERY BUSINESS OWNER CAN USE

For the most part, every now and then, it won't be inappropriate to post something non-business related. Show your Twitter followers what your office looks like or introduce them to someone they may talk to a lot on the phone. Help customers feel like they are truly connected to you and they'll pay you back.

Stick to One Platform (at First)

It's never a good idea to spread yourself too thin. Most business owners know that doing so can produce extremely detrimental effects. Yet, when it comes to social media, many seem all too happy to do so.

At the beginning, pick just one platform and learn to master it. Preferably, you want to choose Facebook, Twitter or LinkedIn (maybe even Pinterest best for some). Then spend time really getting comfortable with it. Read books on your platform of choice or watch YouTube videos about it. Nothing is worse than a business owner who clearly doesn't understand the intricacies of the platforms they are posting on.

Don't Forget About YouTube

That being said, don't forget that YouTube is a social media platform, too. It's also owned by Google, which means that YouTube content is always good for SEO.

Once you've mastered one of the platforms we mentioned above, start involving YouTube. This video channel isn't just great for SEO; it's also amazing for building engaging content your customers can consume quickly.

Use Social Media to Draw Your Leads

You shouldn't think of your social media content as a one-way street. Yes, you want eyes on your content, but why stop there? As a business owner, you should constantly be trying to draw leads whenever you can. What better time than when someone is already reading a post or watching a video?

RELATED: TOP 6 PODCASTS FOR ENTREPRENEURS 

Don't go overboard though. You don't want your customers to get used to the idea that you'll only give them something they want if they give you an email address or phone number first. Show them that your content is worth their time and, every now and then, move to generate leads.

Social media is far too powerful a tool to be ignored. If you're a business owner who hasn't been actively using it on a regular basis, then take the advice above and begin today.

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.

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