cf_specials
Specials Custom Tag:
Show Specials (and anything else) Custom Tag
Shows a formatted display of categories, specials, etc.,
and images if specified.
Click on products separately or click to show all specials.
May be set to any category ID so you can show different items
with this tag, such as New Items, Discontinued Items, etc.
Use the tag as many times as you wish per page, setting a
different category ID for each. May also pass the category
parameter as part of a query string as subcat=[category id]
and place category="#subcat#" in the tag.
Passing no category (subcat) into this tag will show specials. Handy Dandy Tag!
page=list.cfm or page=details.cfm (see details="1/0" attribute)
Copy and paste below into template:
<cf_specials
id="#variables.id#"
afid="#afid#"
thispage="#page#">
Minimum required parameters:
id="#variables.id#" DO NOT REMOVE OR CHANGE!
afid="#afid#" DO NOT REMOVE OR CHANGE!
thispage="#page#" DO NOT REMOVE OR CHANGE!
Optional parameters:
cartpage="#cartpage#" If you defined the cartpage variable in the
template, add this.
category="[category_id]" If number specified, will show only items in the
category of your choice. Otherwise will show items
in a category named Specials and items with a Sale
Price of greater than 0 and less than the regular
price.
products="item1,item2,etc" A comma delimted list of Product IDs. Will overwrite
any value in category above. Leave blank or omit to
use the category variable.
details="1/0" This will send the user to the details page as
though they clicked on details from the search
results page. When they click "Continue Shopping" it
will send them back to show this tag provided you
set the follwing code in the top of your cartpage
template:
<cfset returnpage = "specials">
Be sure to call this tag with page=specials or the
link back from details will go to the wrong place.
This parameter defaults to "0" if blank or ommited
and sends the user to the regular search results
page.
images="path/to/images/" Defaults to no product images if omitted or blank.
Otherwise, enter the path to the directory where the
product images are and include a trailing slash.
Name the images "'product id'.jpg".
imagepath="sub/main" Covered in Add Products under "Product Image Naming
Convention and Placement". This should match the
setting (if any) you entered in Application.cfm.
linkall="above/below" Add this to put a link using the text below to show
all items being shown by this tag. Place it above or
below the items. Omit this tag (or leave blank) for
no link to all items.
linkalltext="[text]" Text to show as link to all products for linkall if
used. Defaults to "View All Items Shown".
linkallfontclass="[style]" Font style of linkall text if used. Defaults to
ezcarttext if omitted.
linkalllinkclass="[style]" Link style of linkall text if used. Defaults to
ezcart if omitted.
linkallfontcolor="[hex]" Use a hex value with no pound sign. Defaults to link
color in body.
linkallfontbold="1/0" Defaults to 0 (no) if omitted. 1 sets the linkall
font as bold if used.
fontclass="[style]" Defaults to ezcartsmalltext if omitted. Style of all
descriptive text.
linkfontcolor="[hex]" Use a hex value with no pound sign. Defaults to link
color in body tag if omitted.
linkfontbold="1/0" Defaults to 0 (no) if omitted. 1 sets the linkall
font as bold if used.
showprice="1/0" Set to "0" to hide the price. Defaults to "1" (yes)
if anything other than "0" or omitted.
salefont="[style]" The style of the sale price. Defaults to
salefontcolor if omitted. Any item that has been set
to a special price by setting the sale price less
than the regular price, as opposed to just placing
it in a category named "Specials" will show the
regular price under the sale price with a strike
thru it (KEWL!).
salefontbold="1" Defaults to 0 (no) if omitted. 1 sets the font bold.
cols="[number]" Columns In Table. Defaults to 1 if omitted.
showitems="[number]" If you have alot of items showing in the categories
or specials you are showing here, you can specify
the max number to show per page. This will give a
cool previous/next links below the items. You must
use page=specials to call the tag and use the
startrow parameter below.
startrow="#startrow#" If using showitems above, paste this in exactly like
this.
border="[number]" Table border size. Defaults to 1 if omitted.
tablewidth="[number or %]" Table width. Defaults to none if omitted & table
will size dynamically.
spacing="[number]" Table cellspacing. Defaults to 0 if omitted.
padding="[number]" Table cellpadding. Defaults to 2 if omitted.
bordercolor="[hex]" Table bodercolor. Defaults to no bordercolor if
omitted or blank.
aligncell="[alignment]" Defaults to center if omitted. Valid values are
left/center/right/both. "both" may only be used if
cols="2" in which case the left column will be left
justified and the right column will be right
justified. Using "both" with cols set to anything
other than "2" will center justify.
valigncell="[alignment]" Vertical alignment of main table cells. Valid values
are top, middle, bottom. Defaults to "top".
subtablewidth="[num or %]" Sub table width. We place the text inside of a table
that can be sized. This Defaults to none if omitted
& table will size dynamically. This will allow you
to align your text to the width of your images if
using images or just lets you make all your text
blocks be the same width. Play with this and the
table cells.
subaligncell="[alignment]" Same as aligncell but works on the table with the
text. A nice look if using images is to set this to
"left" and make the subtablewidth the same width as
the images.