Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

34 lines (26 sloc) 1.242 kb
<cfcomponent accessors="true">
<cfproperty name="Crouton" type="Crouton" />
<cfproperty name="PageURL" type="string" default="" />
<cffunction name="init" returntype="AmazonApp">
<cfargument name="Crouton" type="Crouton" required="yes" />
<cfset setCrouton( Arguments.Crouton ) />
<cfreturn this />
<cffunction name="getDaily" returntype="string">
<cfset var XML = getCrouton().parse( getPageURL() ) />
<cfset var Img = XMLSearch( XML, "//div[@class='fad-widget-large-artwork']//img" )[1].XmlAttributes.Src />
<cfset var AppName = XMLSearch( XML, "//div[@class='app-info-name']/a" )[1].XMLText />
<cfset var BuyLink = XMLSearch( XML, "//div[@class='app-info-name']/a" )[1].XmlAttributes.Href />
<cfset var Description = XMLSearch( XML, "//img[@class='fad-widget-large-description']" )[1].XMLAttributes.Alt />
<cfset var EmailContents = '' />
<cfsavecontent variable="EmailContents">
<h1>Amazon Daily Android App</h1>
<h2><a href="">#AppName#</a></h2>
<img src="#Img#" />
<cfreturn EmailContents />
Jump to Line
Something went wrong with that request. Please try again.