root/trunk/website/org/camden/blog/render/amazonbox.cfc @ 5

Revision 5, 0.9 kB (checked in by DanWilson, 17 years ago)

Initial Commit Of ModelGlue? Website (upgrade to blogcfc 511)

Line 
1<cfcomponent extends="render" instructions="To place an left-aligned Amazon 'box' for a product, use: <amazonbox asin=""x"" affiliate=""y"">">
2
3<cffunction name="display">
4        <cfargument name="asin" type="string" required="false" default="">
5        <cfargument name="affiliate" type="string" required="false" default="raymondcamden-20">
6       
7        <cfset var result = "">
8
9        <cfif len(arguments.asin) and len(arguments.affiliate)>
10                <cfsavecontent variable="result">
11                <cfoutput>
12<iframe src="http://rcm.amazon.com/e/cm?t=#arguments.affiliate#&o=1&p=8&l=as1&asins=#arguments.asin#&fc1=000000&IS2=1&lt1=_top&lc1=0000ff&bc1=000000&bg1=ffffff&npa=1&f=ifr" style="width:120px;height:240px;margin-right: 10px" scrolling="no" marginwidth="0" marginheight="0" frameborder="0" align="left"></iframe>
13                </cfoutput>
14                </cfsavecontent>
15        </cfif>
16               
17        <cfreturn result>
18</cffunction>
19
20</cfcomponent>
Note: See TracBrowser for help on using the browser.