Example - BBC News live headlines

HTML output retrieves first article from http://news.bbc.co.uk/. Output is refreshing each 15 minutes from cron.

 

Output:

<p><h3><a href="http://www.bbc.com">Corbyn: General election will stop Brexit &#x27;crisis&#x27;</a></h3></p>
<p>A general election would be the &quot;change of direction&quot; the UK needs, the Labour leader has said.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">Corbyn: General election will stop Brexit &#x27;crisis&#x27;</a></h3></p>
<p>A general election would be the &quot;change of direction&quot; the UK needs, the Labour leader has said.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">Freedom of movement &#x27;will end&#x27; after Brexit</a></h3></p>
<p>The government has ditched the idea of extending freedom of movement to 2021 in the event of a no-deal.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">The back injury &#x27;costing the NHS millions&#x27;</a></h3></p>
<p>Cauda equina syndrome requires decompression surgery within hours to avoid catastrophic damage.</p>
<p>Time: </p>
<p>Category: Health</p>
<p><h3><a href="http://www.bbc.com">Silicone buttock death accused extradited to US</a></h3></p>
<p>Donna Francis is accused of killing Kelly Mayhew in a &quot;botched butt enhancement&quot; procedure in 2015.</p>
<p>Time: </p>
<p>Category: Essex</p>
<p><h3><a href="http://www.bbc.com">Police given more time to quiz PC murder suspects</a></h3></p>
<p>PC Andrew Harper was dragged along the road by a vehicle after responding to burglary reports.</p>
<p>Time: </p>
<p>Category: Berkshire</p>
<p><h3><a href="http://www.bbc.com">Andrew &#x27;appalled&#x27; by Epstein&#x27;s sex abuse claims</a></h3></p>
<p>The idea he would &quot;condone or participate in&quot; exploitation is abhorrent, Buckingham Palace says.</p>
<p>Time: </p>
<p>Category: UK</p>
<p><h3><a href="http://www.bbc.com">A young face scarred by Syria war</a></h3></p>
<p>Jouma and his family were fleeing their home when an air strike hit, leaving him blind aged three.</p>
<p>Time: </p>
<p>Category: Middle East</p>
<p><h3><a href="http://www.bbc.com">A young face scarred by Syria war</a></h3></p>
<p>Jouma and his family were fleeing their home when an air strike hit, leaving him blind aged three.</p>
<p>Time: </p>
<p>Category: Middle East</p>
<p><h3><a href="http://www.bbc.com">French couple face jail over Sardinian sand theft</a></h3></p>
<p>They say they wanted the sand as a &quot;souvenir&quot; and did not realise they were committing an offence.</p>
<p>Time: </p>
<p>Category: Europe</p>
<p><h3><a href="http://www.bbc.com">Police escape injury in bomb attack</a></h3></p>
<p>It is being described as a &quot;deliberate attempt&quot; to lure security personnel into an area &quot;to murder them&quot;.</p>
<p>Time: </p>
<p>Category: Northern Ireland</p>
<p><h3><a href="http://www.bbc.com">Paralympian denies sexually assaulting woman</a></h3></p>
<p>Lord Holmes of Richmond is accused of touching the woman in a London hotel earlier this year.</p>
<p>Time: </p>
<p>Category: London</p>
<p><h3><a href="http://www.bbc.com">Boris Johnson orders action to stop measles spread</a></h3></p>
<p>A fall in uptake of the MMR vaccine means the UK has lost its measles-free status.</p>
<p>Time: </p>
<p>Category: Health</p>
<p><h3><a href="http://www.bbc.com">Thousands flee out-of-control Gran Canaria fires</a></h3></p>
<p>Hundreds of firefighters are tackling the wildfires that are tearing through the holiday island.</p>
<p>Time: </p>
<p>Category: Europe</p>
<p><h3><a href="http://www.bbc.com">Hopes fade for stolen blind hedgehog&#x27;s return</a></h3></p>
<p>Stephen the hedgehog was inside a van, which was stolen in Leeds on Saturday morning.</p>
<p>Time: </p>
<p>Category: Humberside</p>
<p><h3><a href="http://www.bbc.com">Corbyn: General election will stop Brexit &#x27;crisis&#x27;</a></h3></p>
<p>A general election would be the &quot;change of direction&quot; the UK needs, the Labour leader has said.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">Corbyn: General election will stop Brexit &#x27;crisis&#x27;</a></h3></p>
<p>A general election would be the &quot;change of direction&quot; the UK needs, the Labour leader has said.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">Freedom of movement &#x27;will end&#x27; after Brexit</a></h3></p>
<p>The government has ditched the idea of extending freedom of movement to 2021 in the event of a no-deal.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">The back injury &#x27;costing the NHS millions&#x27;</a></h3></p>
<p>Cauda equina syndrome requires decompression surgery within hours to avoid catastrophic damage.</p>
<p>Time: </p>
<p>Category: Health</p>
<p><h3><a href="http://www.bbc.com">Silicone buttock death accused extradited to US</a></h3></p>
<p>Donna Francis is accused of killing Kelly Mayhew in a &quot;botched butt enhancement&quot; procedure in 2015.</p>
<p>Time: </p>
<p>Category: Essex</p>
<p><h3><a href="http://www.bbc.com">Police given more time to quiz PC murder suspects</a></h3></p>
<p>PC Andrew Harper was dragged along the road by a vehicle after responding to burglary reports.</p>
<p>Time: </p>
<p>Category: Berkshire</p>
<p><h3><a href="http://www.bbc.com">Andrew &#x27;appalled&#x27; by Epstein&#x27;s sex abuse claims</a></h3></p>
<p>The idea he would &quot;condone or participate in&quot; exploitation is abhorrent, Buckingham Palace says.</p>
<p>Time: </p>
<p>Category: UK</p>
<p><h3><a href="http://www.bbc.com">A young face scarred by Syria war</a></h3></p>
<p>Jouma and his family were fleeing their home when an air strike hit, leaving him blind aged three.</p>
<p>Time: </p>
<p>Category: Middle East</p>
<p><h3><a href="http://www.bbc.com">A young face scarred by Syria war</a></h3></p>
<p>Jouma and his family were fleeing their home when an air strike hit, leaving him blind aged three.</p>
<p>Time: </p>
<p>Category: Middle East</p>
<p><h3><a href="http://www.bbc.com">French couple face jail over Sardinian sand theft</a></h3></p>
<p>They say they wanted the sand as a &quot;souvenir&quot; and did not realise they were committing an offence.</p>
<p>Time: </p>
<p>Category: Europe</p>
<p><h3><a href="http://www.bbc.com">Police escape injury in bomb attack</a></h3></p>
<p>It is being described as a &quot;deliberate attempt&quot; to lure security personnel into an area &quot;to murder them&quot;.</p>
<p>Time: </p>
<p>Category: Northern Ireland</p>
<p><h3><a href="http://www.bbc.com">Paralympian denies sexually assaulting woman</a></h3></p>
<p>Lord Holmes of Richmond is accused of touching the woman in a London hotel earlier this year.</p>
<p>Time: </p>
<p>Category: London</p>
<p><h3><a href="http://www.bbc.com">Boris Johnson orders action to stop measles spread</a></h3></p>
<p>A fall in uptake of the MMR vaccine means the UK has lost its measles-free status.</p>
<p>Time: </p>
<p>Category: Health</p>
<p><h3><a href="http://www.bbc.com">Thousands flee out-of-control Gran Canaria fires</a></h3></p>
<p>Hundreds of firefighters are tackling the wildfires that are tearing through the holiday island.</p>
<p>Time: </p>
<p>Category: Europe</p>
<p><h3><a href="http://www.bbc.com">Hopes fade for stolen blind hedgehog&#x27;s return</a></h3></p>
<p>Stephen the hedgehog was inside a van, which was stolen in Leeds on Saturday morning.</p>
<p>Time: </p>
<p>Category: Humberside</p>
<p><h3><a href="http://www.bbc.com">Corbyn: General election will stop Brexit &#x27;crisis&#x27;</a></h3></p>
<p>A general election would be the &quot;change of direction&quot; the UK needs, the Labour leader has said.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">Corbyn: General election will stop Brexit &#x27;crisis&#x27;</a></h3></p>
<p>A general election would be the &quot;change of direction&quot; the UK needs, the Labour leader has said.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">Freedom of movement &#x27;will end&#x27; after Brexit</a></h3></p>
<p>The government has ditched the idea of extending freedom of movement to 2021 in the event of a no-deal.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">People &#x27;afraid to speak up&#x27; in Lyra McKee probe</a></h3></p>
<p>Lyra McKee&#x27;s partner says she understands the hold some groups have over communities in NI.</p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">The back injury &#x27;costing the NHS millions&#x27;</a></h3></p>
<p>Cauda equina syndrome requires decompression surgery within hours to avoid catastrophic damage.</p>
<p>Time: </p>
<p>Category: Health</p>
<p><h3><a href="http://www.bbc.com">Silicone buttock death accused extradited to US</a></h3></p>
<p>Donna Francis is accused of killing Kelly Mayhew in a &quot;botched butt enhancement&quot; procedure in 2015.</p>
<p>Time: </p>
<p>Category: Essex</p>
<p><h3><a href="http://www.bbc.com">Police given more time to quiz PC murder suspects</a></h3></p>
<p>PC Andrew Harper was dragged along the road by a vehicle after responding to burglary reports.</p>
<p>Time: </p>
<p>Category: Berkshire</p>
<p><h3><a href="http://www.bbc.com">Andrew &#x27;appalled&#x27; by Epstein&#x27;s sex abuse claims</a></h3></p>
<p>The idea he would &quot;condone or participate in&quot; exploitation is abhorrent, Buckingham Palace says.</p>
<p>Time: </p>
<p>Category: UK</p>
<p><h3><a href="http://www.bbc.com">Andrew &#x27;appalled&#x27; by Epstein&#x27;s sex abuse claims</a></h3></p>
<p>The idea he would &quot;condone or participate in&quot; exploitation is abhorrent, Buckingham Palace says.</p>
<p>Time: </p>
<p>Category: UK</p>
<p><h3><a href="http://www.bbc.com">A young face scarred by Syria war</a></h3></p>
<p>Jouma and his family were fleeing their home when an air strike hit, leaving him blind aged three.</p>
<p>Time: </p>
<p>Category: Middle East</p>
<p><h3><a href="http://www.bbc.com">French couple face jail over Sardinian sand theft</a></h3></p>
<p>They say they wanted the sand as a &quot;souvenir&quot; and did not realise they were committing an offence.</p>
<p>Time: </p>
<p>Category: Europe</p>
<p><h3><a href="http://www.bbc.com">Police escape injury in bomb attack</a></h3></p>
<p>It is being described as a &quot;deliberate attempt&quot; to lure security personnel into an area &quot;to murder them&quot;.</p>
<p>Time: </p>
<p>Category: Northern Ireland</p>
<p><h3><a href="http://www.bbc.com">Paralympian denies sexually assaulting woman</a></h3></p>
<p>Lord Holmes of Richmond is accused of touching the woman in a London hotel earlier this year.</p>
<p>Time: </p>
<p>Category: London</p>
<p><h3><a href="http://www.bbc.com">Boris Johnson orders action to stop measles spread</a></h3></p>
<p>A fall in uptake of the MMR vaccine means the UK has lost its measles-free status.</p>
<p>Time: </p>
<p>Category: Health</p>
<p><h3><a href="http://www.bbc.com">Thousands flee out-of-control Gran Canaria fires</a></h3></p>
<p>Hundreds of firefighters are tackling the wildfires that are tearing through the holiday island.</p>
<p>Time: </p>
<p>Category: Europe</p>
<p><h3><a href="http://www.bbc.com">Corbyn: General election will stop Brexit &#x27;crisis&#x27;</a></h3></p>
<p>A general election would be the &quot;change of direction&quot; the UK needs, the Labour leader has said.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">Corbyn: General election will stop Brexit &#x27;crisis&#x27;</a></h3></p>
<p>A general election would be the &quot;change of direction&quot; the UK needs, the Labour leader has said.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">Freedom of movement &#x27;will end&#x27; after Brexit</a></h3></p>
<p>The government has ditched the idea of extending freedom of movement to 2021 in the event of a no-deal.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">The back injury &#x27;costing the NHS millions&#x27;</a></h3></p>
<p>Cauda equina syndrome requires decompression surgery within hours to avoid catastrophic damage.</p>
<p>Time: </p>
<p>Category: Health</p>
<p><h3><a href="http://www.bbc.com">Silicone buttock death accused extradited to US</a></h3></p>
<p>Donna Francis is accused of killing Kelly Mayhew in a &quot;botched butt enhancement&quot; procedure in 2015.</p>
<p>Time: </p>
<p>Category: Essex</p>
<p><h3><a href="http://www.bbc.com">Police given more time to quiz PC murder suspects</a></h3></p>
<p>PC Andrew Harper was dragged along the road by a vehicle after responding to burglary reports.</p>
<p>Time: </p>
<p>Category: Berkshire</p>
<p><h3><a href="http://www.bbc.com">Vegetable joke is funniest at the Fringe</a></h3></p>
<p>A culinary pun from Swedish comedian Olaf Falafel takes the prize for top gag at the Edinburgh festival.</p>
<p>Time: </p>
<p>Category: Edinburgh, Fife &amp; East Scotland</p>
<p><h3><a href="http://www.bbc.com">Andrew &#x27;appalled&#x27; by Epstein&#x27;s sex abuse claims</a></h3></p>
<p>The idea he would &quot;condone or participate in&quot; exploitation is abhorrent, Buckingham Palace says.</p>
<p>Time: </p>
<p>Category: UK</p>
<p><h3><a href="http://www.bbc.com">Andrew &#x27;appalled&#x27; by Epstein&#x27;s sex abuse claims</a></h3></p>
<p>The idea he would &quot;condone or participate in&quot; exploitation is abhorrent, Buckingham Palace says.</p>
<p>Time: </p>
<p>Category: UK</p>
<p><h3><a href="http://www.bbc.com">A young face scarred by Syria war</a></h3></p>
<p>Jouma and his family were fleeing their home when an air strike hit, leaving him blind aged three.</p>
<p>Time: </p>
<p>Category: Middle East</p>
<p><h3><a href="http://www.bbc.com">French couple face jail over Sardinian sand theft</a></h3></p>
<p>They say they wanted the sand as a &quot;souvenir&quot; and did not realise they were committing an offence.</p>
<p>Time: </p>
<p>Category: Europe</p>
<p><h3><a href="http://www.bbc.com">Police escape injury in bomb attack</a></h3></p>
<p>It is being described as a &quot;deliberate attempt&quot; to lure security personnel into an area &quot;to murder them&quot;.</p>
<p>Time: </p>
<p>Category: Northern Ireland</p>
<p><h3><a href="http://www.bbc.com">Paralympian denies sexually assaulting woman</a></h3></p>
<p>Lord Holmes of Richmond is accused of touching the woman in a London hotel earlier this year.</p>
<p>Time: </p>
<p>Category: London</p>
<p><h3><a href="http://www.bbc.com">Thousands flee out-of-control Gran Canaria fires</a></h3></p>
<p>Hundreds of firefighters are tackling the wildfires that are tearing through the holiday island.</p>
<p>Time: </p>
<p>Category: Europe</p>
<p><h3><a href="http://www.bbc.com">Hopes fade for stolen blind hedgehog&#x27;s return</a></h3></p>
<p>Stephen the hedgehog was inside a van, which was stolen in Leeds on Saturday morning.</p>
<p>Time: </p>
<p>Category: Humberside</p>
<p><h3><a href="http://www.bbc.com">Corbyn: General election will stop Brexit &#x27;crisis&#x27;</a></h3></p>
<p>A general election would be the &quot;change of direction&quot; the UK needs, the Labour leader has said.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">Corbyn: General election will stop Brexit &#x27;crisis&#x27;</a></h3></p>
<p>A general election would be the &quot;change of direction&quot; the UK needs, the Labour leader has said.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">Freedom of movement &#x27;will end&#x27; after Brexit</a></h3></p>
<p>The government has ditched the idea of extending freedom of movement to 2021 in the event of a no-deal.</p>
<p>Time: </p>
<p>Category: UK Politics</p>
<p><h3><a href="http://www.bbc.com">The back injury &#x27;costing the NHS millions&#x27;</a></h3></p>
<p>Cauda equina syndrome requires decompression surgery within hours to avoid catastrophic damage.</p>
<p>Time: </p>
<p>Category: Health</p>
<p><h3><a href="http://www.bbc.com">Silicone buttock death accused extradited to US</a></h3></p>
<p>Donna Francis is accused of killing Kelly Mayhew in a &quot;botched butt enhancement&quot; procedure in 2015.</p>
<p>Time: </p>
<p>Category: Essex</p>
<p><h3><a href="http://www.bbc.com">Police given more time to quiz PC murder suspects</a></h3></p>
<p>PC Andrew Harper was dragged along the road by a vehicle after responding to burglary reports.</p>
<p>Time: </p>
<p>Category: Berkshire</p>
<p><h3><a href="http://www.bbc.com">Andrew &#x27;appalled&#x27; by Epstein&#x27;s sex abuse claims</a></h3></p>
<p>The idea he would &quot;condone or participate in&quot; exploitation is abhorrent, Buckingham Palace says.</p>
<p>Time: </p>
<p>Category: UK</p>
<p><h3><a href="http://www.bbc.com">A young face scarred by Syria war</a></h3></p>
<p>Jouma and his family were fleeing their home when an air strike hit, leaving him blind aged three.</p>
<p>Time: </p>
<p>Category: Middle East</p>
<p><h3><a href="http://www.bbc.com">A young face scarred by Syria war</a></h3></p>
<p>Jouma and his family were fleeing their home when an air strike hit, leaving him blind aged three.</p>
<p>Time: </p>
<p>Category: Middle East</p>
<p><h3><a href="http://www.bbc.com">French couple face jail over Sardinian sand theft</a></h3></p>
<p>They say they wanted the sand as a &quot;souvenir&quot; and did not realise they were committing an offence.</p>
<p>Time: </p>
<p>Category: Europe</p>
<p><h3><a href="http://www.bbc.com">Police escape injury in bomb attack</a></h3></p>
<p>It is being described as a &quot;deliberate attempt&quot; to lure security personnel into an area &quot;to murder them&quot;.</p>
<p>Time: </p>
<p>Category: Northern Ireland</p>
<p><h3><a href="http://www.bbc.com">Paralympian denies sexually assaulting woman</a></h3></p>
<p>Lord Holmes of Richmond is accused of touching the woman in a London hotel earlier this year.</p>
<p>Time: </p>
<p>Category: London</p>
<p><h3><a href="http://www.bbc.com">Boris Johnson orders action to stop measles spread</a></h3></p>
<p>A fall in uptake of the MMR vaccine means the UK has lost its measles-free status.</p>
<p>Time: </p>
<p>Category: Health</p>
<p><h3><a href="http://www.bbc.com">Thousands flee out-of-control Gran Canaria fires</a></h3></p>
<p>Hundreds of firefighters are tackling the wildfires that are tearing through the holiday island.</p>
<p>Time: </p>
<p>Category: Europe</p>
<p><h3><a href="http://www.bbc.com">Bakery badly damaged by &#x27;very large&#x27; fire</a></h3></p>
<p>An eyewitness says the fire on Wrexham Industrial Estate spewed out &quot;huge flames&quot;.</p>
<p>Time: </p>
<p>Category: Wales</p>
<p><h3><a href="http://www.bbc.com">Ariana Grande enjoys &#x27;magical&#x27; return to UK</a></h3></p>
<p></p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">BBC News Channel</a></h3></p>
<p>The latest breaking and developing stories</p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">BBC Radio 5 Live</a></h3></p>
<p>Original news and exclusive interviews</p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">Bus shelter mysteriously made into cosy room</a></h3></p>
<p></p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">&#x27;Nightmare&#x27; statue looms over New Zealand city</a></h3></p>
<p></p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">Russian&#x27;s 1969 message in a bottle found in Alaska</a></h3></p>
<p></p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">Could floating farms be the future?</a></h3></p>
<p></p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">He-Man revival heading for Netflix</a></h3></p>
<p></p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">The Nazi book of anatomy still used by surgeons</a></h3></p>
<p></p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">The plan to force companies to be no-deal ready</a></h3></p>
<p></p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">What is the UK doing to get ready for a no-deal Brexit?</a></h3></p>
<p></p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">&#x27;I feared they&#x27;d take my child if I admitted how I felt&#x27;</a></h3></p>
<p></p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">BBC News tries out Three&#x27;s 5G for the home</a></h3></p>
<p></p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">How online extremists shape minds of white teens</a></h3></p>
<p></p>
<p>Time: </p>
<p>Category: </p>
<p><h3><a href="http://www.bbc.com">&#x27;Coming out in football has only felt amazing&#x27;</a></h3></p>
<p></p>
<p>Time: </p>
<p>Category: </p>

Source code of script:

# File: bbc_main.w
# Name: BBC News live headlines
# Description: HTML output retrieves first article from www.bbcnews.com
# Input: URL [http://news.bbc.co.uk]
# Output format: HTML file
# Output fields: Source URL, Link, Title, Description

#<Logger File>
#	Global
#	FileName bbc_log.log
#	Level debug
#</Logger>

<Section>
    Name bbc_main
	
    Define $output_file bbc_output.html

	# define variable $url and assign it value
    Define $url http://www.bbc.com/news
    
	
	
    # clean output file
    <Action Print>
        FileName {$output_file}
		FileMode Write  
    </Action>
    	
	
    
    # load content
    <Action ContentURL>
        URL {$url}
        RemoveNewLine
        TagsToStrip br,nobr,b
    </Action>

	# the script will iterate through all headlines
	<Section While>
		# search for headlines only in the top part of the website
		EndAt <div class="container">
		
		# match the beginning of headline
		<Pattern>
			RegExp <div class="gs-c-promo-body
		</Pattern>
	
		<Section>
			# stop searching for date before the beginning of next headline
			EndAt <div class="gel-layout__item
	
			# match url
			<Pattern>
				RegExp <a class="gs-c-promo-heading{:re([^"]*)}" href="{$url:re([^"]*)}">
				Trim
				Compact
			</Pattern>
	
			# match title
			<Pattern>
				RegExp <h3 class="gs-c-promo-heading__title{:re([^"]*)}">{$title}</h3></a>
				Trim
				Compact
			</Pattern>
	
			# match summary
			<Pattern>
				Optional
				RegExp <p class="gs-c-promo-summary{:re([^"]*)}">{$summary}</p>
				Trim
				Compact
			</Pattern>
	
			# match time
			<Pattern>
				Optional
				RegExp <time class="gs-o-bullet__text date qa-status-date" datetime="{$time:re([^"]*)}"
				Trim
				Compact
			</Pattern>
	
			# match category
			<Pattern>
				Optional
				RegExp <span aria-hidden="true">{$category}</span>
				Trim
				Compact
			</Pattern>
	
			# and print parsed data
			<Action Print>
				FileName {$output_file}
				Text <p><h3><a href="http://www.bbc.com{$link}">{$title}</a></h3></p>\n<p>{$summary}</p>\n<p>Time: {$time}</p>\n<p>Category: {$category}</p>\n
			</Action>
        </Section>
    </Section>
</Section>

Main bbc_main