/* Popular phrases - GREENMOUNTAINCOFFEE - 16:58:27, Fri Nov 20, 2009 */
__SLI_ClientDefaults =
[
    ['UseHTTPS', true]
];
var asPhrases=new Array ('vanilla','pumpkin spice coffee','pumpkin spice k-cup','hot cocoa k cups','mugs','decaf k cups','holiday blend','holiday k-cup','eggnog','gingerbread k cups','seasonal k cups','cafe escapes','80 count kcup','caribou k cups','pumpkin spice','eggnog k cup','hot chocolate k-cups','breakfast blend k cups','kona','gingerbread','chai latte','french roast','blueberry','pumpkin','spicy eggnog k cups','half caff k-cup','hazelnut k cup','decaf','hot cocoa','donut house','carousel','cafe mocha','seasonal flavors','tea','variety k-cups','cocoa k-cups','pumpkin coffee','chai','nantucket blend k-cups','espresso k cup','t6774','hazelnut','filters','tea k-cups','spicy eggnog','mocha','our blend','dark magic','breakfast blend','kona k cups','pumpkin spice k cup','holiday','t6502','rain forest nut','blueberry k cup','hot chocolate','t6801','t6803','travel mug','french vanilla k-cups','tea sampler','newmans','cocoa','lake and lodge k cups','free keurig','colombian','nantucket blend','newmans special blend','southern pecan','mocha nut fudge k-cups','sampler','vermont country blend k cup','caribou','donut','green tea k-cups','t6635','iced tea k cups','rain forest nut coffee','newmans extra bold','french vanilla','flavored variety k-cup sampler','french roast k cup','coffee mugs','k cup sampler','t6501','k-cup carousel','our blend k cup','dark magic k-cups','wild mountain blueberry k-cups','t4000','k cups','limited edition','brewers','variety','caramel vanilla cream k-cup','italian roast','donut house k cups','frother','vermont country blend','hazelnut decaf','seasonal tour','decaf sampler','latte','extra bold','espresso','t6742','t6802','gift certificate','my k-cup','t6722','colombian fair trade select','milk chocolate hot cocoa k-cup','t6715','newmans special blend k cups','descale','t6507','rain forest nut k-cup','t6534','80','chocolate','breville','mocha java','my k cup adapter','cinnamon','sumatran reserve k-cups','holiday coffee','bodum','t6732','kcups','t6520','breakfast blend decaf','iced tea','french roast decaf','decaf coffee','lake and lodge','chai tea k-cups','keurig brewer','wild mountain blueberry','heifer hope blend','b40','caramel vanilla cream','biscotti','t6503','newmans special decaf','green tea','t6505','ethiopian yirgacheffe','t6504','t6700','nantucket','thermos','seasonal','maple butter','dark chocolate k cup','t6694','earl grey k-cup','t4061','vanilla cream','house blend','southern pecan k cup','colombian k cup','b140','k-cup tea','chocolate glazed donut','mini brewer','marshmallows','organic decaf','hazelnut coffee','t6823','k-cup','cinnamon roll','b70','bodum mugs','sumatran','keurig','k cup variety','espresso k-cup','80 count','t6821','english breakfast tea k-cups','k cup hot chocolate','jason silverman mugs','t6992','sumatran reserve','decaf k-cups','pbs','chai tea','mahogany','organic k cup','yirgacheffe','t6783','adapter','coffee pods','maple syrup','k cup chai tea','autumn harvest','kenyan highland cooperatives','french press','t6663','tea variety','pbs blend','raspberry','tanzanian gombe reserve','organic k-cups','double black diamond','t6760','t6999','peppermint puffs','milk frother','vermont country blend decaf','t6752','tullys','basket','kona coffee','t6772','sumatra','lava','k-cups','t6792','flavored coffee','newmans 80 count','special reserve','sleepytime tea k-cups','cinnamon cream swirl','heifer hope k-cup','office pro','perfect iced tea','k-cup sampler','vine mug','carafe','kenyan aa','extra bold variety k-cup sampler','k-cup flavors','variety sampler','seasonal coffee','t6822','keurig travel mug','organic house blend','mocha nut fudge','80 ct','t7522','b145','caramel','lemon zinger tea k cup','half caff','hazelnut decaf k cup','nutcracker cookies','flavored k cups','pbs blend k cups','tullys french roast','t4059','our blend k-cups','mocha k cups','chocolate glazed','t6824','nell','french vanilla decaf','t4068','caribou blend','t4067','k-cup decaf','pecan','k cup filter','t7732','dark roast','double black diamond extra bold','flavored decaf coffee','b30','flavored','old world hot cocoa','t6990','gift baskets','bold k cups','vermont','medium roast k-cups','kenyan','t7534','half and half k cups','peach k-cup','b-60','keurig single cup brewer','tour','grinder','almond biscotti','keurig filter','escapes','fair trade k cup','pancake','my k-cup refill pack','heifer','organic vanilla cream','t6570','peach coffee','zhena','colombian fair trade select k-cup','my k-cup adapter','t4066','lava cake','caramel vanilla','travel coffee mugs','national wildlife blend','organic','madison blend','sumatran lake tawar','rain forest nut decaf','italian','nissan thermos','national wildlife k cup','t6523','t4060','t7792','t6602','my kcup','scoop','mandarin orange spice tea','pumpkin k cup','keurig carousel','variety box','holiday flavors','k cup carousel','harvard blend','my k cup','80 ct boxes','coffee press','daybreak morning blend','hazelnut dark roast extra bold','chocolate covered marshmallows','decaf coffee kcups','sugar free','celestial seasonings tea','regular variety','seasonal flavors coffee tour','breakfast blend decaf k-cup','k cup coffee','t6998','k cup teas','tumbler','chocolate coffee','water filter','tower','platinum','glasses','tullys decaf','donut house coffee','backpack thermos','t6501 k-cup','t7602','flavored decaf','lake','stoneware mug','decaf variety','fair trade','chai tea latte','nissan thermal press','b200','dark magic decaf','80 k cups','southern pecan decaf','dark chocolate','evergreen','preserves','bold','tree','t6503 decaf variety k-cup sampler','costa rican peaberry','raspberry iced tea','lake and lodge bean','office brewers','kona blend k cup','sumatra k cup','guatemalan finca dos marias','newman k cups','chocolate raspberry truffle','coffee','bold sampler','coffee scoop','storage baskets','iced tea cup','nell\'s','granola','full city','decaf kcups','guatemalan','dark magic espresso blend','flavored sampler','pumpkin flavored coffee','espresso blend','t6994','organic sumatran reserve','tullys house blend','dezcal','special reserve coffees','organic french roast','t4057','signature sampler','glazed donut','mexican','keurig sized travel mug','fair trade organic','single-cup coffee machines','bodum glasses','donut house mug','ethiopian','peanut brittle','nell\'s breakfast','brewing iced tea','black tea k-cups','pecan k cup','peach iced tea','french vanilla decaf k cup','wild blueberry','nells breakfast blend','my kcup adapter','rain forest','dezcal cleaner','shade grown','colombian decaf','felicity mug','fair trade organic hot cocoa','cleaner','peach','cookies','mexican select','t6700 caramel vanilla cream','syrup','stackable mugs','perfect peach kcup','pancake mix','extra bold decaf','celestial seasonings','perfect peach','daybreak','chocolate raspberry','celestial teas','hat','half','t6570 k-cup our blend','chocolate lava cake','house blend decaf','t7694','nantucket coffee','t6991','paper filters','breakfast','chai k-cup','extra bold sampler','kcup monthly','cafe almond biscotti','dark magic coffee','t4058','mocha coffee','t6997','sampler box','newman\'s decaf','harvard','k-cup adapter','lemon iced tea k-cup','chocolate marshmallows','keurig b30 mini brewer','autumn','keurig elite','kona mountain estate','mountain blueberry','wildlife blend','#4 filters','lemon zinger','k-cups sampler','bodum insulated glass','decaf caramel vanilla cream','kcup sampler','k-cup basket','hot cocoa k-cups','mug set','decaf bold','water process decaffeinated','organic espresso blend','80 k-cups','b3000','newman decaf','logo mug','beth mueller','cafe escapes chai latte','stainless steel mug','espresso coffees','blueberry k-cups','french vanilla coffee','burr grinder','peaberry','colts','mandarin orange k-cup','coffee beans','keurig coffee','double black diamond k cups','k-cup filter','kcup tree','insulated mugs','popcorn','santos vacuum coffee maker','extra bold dark magic','regular variety k cup','k cup tower','b70 platinum','coffee tumblers','kcup filter','t6995','eggnog k-cup','canister','french roast dark','fair trade organic breakfast blend','t6993','kcup variety','b-70','red french press','highland sugarworks','variety sampler regular','kcup carousel','organic fair trade k-cup','k-cup tree','kcup adapter','raspberry truffle','tanzanian','k-cup decaf coffee','iced tea sampler','costa rican','espresso machine','decaf process','taste of vermont','organic hot cocoa','italian roast k-cup','kona coffee blend','evergreen blend','k-cup tower','bella bark','french vanilla kcup','cinnamon k cups','apron','t4051 newman\'s special decaf','80ct','perfect iced tea cup','raspberry tea','fudge','t4061 dark magic extra bold','thermal press','80 cup','chocolate lava cake mix','elite','nantucket blend coffee','muddy creek','dark hot chocolate','vanilla k-cup','vending','mahogany k cup','regular sampler','nantucket blend k-cup','stem impressions mug','lemon ice tea','national wildlife','caramel vanilla decaf','dark magic decaf extra bold','kenyan highland','flavored k-cups','dark roast extra bold','diner mugs','mini carousel','breakfast tea','donut coffee','mini k cup carousel','keurig special edition','green mountain colombian decaf','silverman','coffee of the month','t6752 mocha nut fudge','flavored variety sampler','rosanna','gombe','80ct k-cup','hazelnut dark roast','b 60','coffee tour','spicy eggnog kcups','water filter cartridges','filter cartridges','hazelnut extra bold','jane goodall coffee','my kcup filter','bagged flavored coffees','t4000 hot cocoa k-cups','nissan','nutcracker','k cup decaf coffee','bodum chambord coffee press','assorted','travel tumbler','press','refills','guatemala','keurig mini','decaf sampler k','cleaning brewer','full city roast','newman\'s special','my k-cup for keurig brewing','organic hot chocolate','holiday k cups','hazelnut k-cups','extra bold hazelnut k cup','free','medium roast','maple','glazed','caramel vanilla kcup','newmans own','milk chocolate hot chocolate','keurig mug','tom homann mug','nissan thermal french press with logo','holiday blend coffee','10','extra bold variety','organic coffee','keurig mini brewer','wildlife','newman\'s sampler','decaf hazelnut coffee','keurig b70','felicity','black diamond','rain forest coffee','holiday blend k-cup','green mug','newman\'s french roast','certificate','single origin','mandarin','stoneware','donut mug','select origin chocolates','flavored variety','earl grey','organic ethiopian yirgacheffe','mild','heifer hope','cafe mocha k cups','natural process','espresso blend k cups','chai k-cups','dark roast k-cup','dark coffee','kcup tea','20','chai tea latte k cups','porcelain','dark','k-cup hot cocoa','house','extra bold espresso','backpack','mini','capresso','basket filters','heritage shortbread','olive wood coffee scoop','hazelnut dark','fall seasonals','donut house decaf','enjoy life mug','tully\'s evergreen','express','french roast k-cup','kona blend','half-caff','vanilla cream coffee','raspberry preserves','chocolate sauce','caribou decaf','finca dos marias','newmans kcup','k-cup cocoa','english black tea','lake champlain','k cup coffee kona','nut','mocha coffee k cups','collection','iced tea brewer','peach flavored coffee','iced','office','cake mix','enjoy life','green tea kcup','fair trade select','mocha java coffee','peach tea','santos','newmans organic special blend','kona k-cup','french roast decaf k cup','decaf sumatra','french','keurig b200','milk chocolate','gombe reserve','k cup flavored sampler','coffee cleaner','my kcup refill filters','black ice tea','sleepytime herbal tea','finca el valle','our blend coffee','decaffeinated','k-cup refill pack','diamond','sleepytime','orange','filter 4','bold variety','fudge nut','ground coffee','chai latte kcups','fair trade spicy eggnog','blueberry green tea','crate','vermont decaf','pumpkin coffee k-cup','tullys kcups','lake champlain cocoa','my k-cup pack','mild coffee k cups','olivewood coffee scoop','regular','italian k cup','special edition','fair trade holiday blend','coffee house coffee','vermont breakfast crate','keurig platinum','tamper','french roast sampler','keurig mini tote','mini red carousel','winkle','80 count k-cups','cinnamon donut house','light decaf','my cup adapter','orange tea','pumpkin spice ground coffee','keurig b30','b30 mini brewer','keurig office pro coffee brewer','cafe escapes cafe mocha','fair trade kcups','b70 brewer','mitzi granola','mexican decaf','cider jelly','pbs k cup','tom homann','goodall','emile henri cherry red mug','k-cup storage baskets','keurig single-cup brewer','celestial english breakfast black tea','better world','lasser','kona mountain','chambord','rancilio','kenyan cooperatives','muddy creek leaf mug','k cup dark magic','tea brewer','travel brewer','gingerbread k-cup','mitzi\'s granola','vermont country decaf','green mountain treasures','fair trade sumatran','kcups assortment','holiday blend kcup','most caffeine','african coffee','bucket','herbal coffee','b30 tote','caps','green mountain flavors','dark decaf k','teastick','b-40','keurig milk frother','k cup basket','coffee brewers','cafe','decaf green tea','my k cup filter','mild coffee','vermont blend','vermont country blend coffee','tote','b-3000','cinnamon swirl','slate mug','coffee canister','decaf variety k-cup sampler','black','mints','unsweetened black tea k-cups','todd piker','flavored coffee tour','light','celestial variety','select','limited edition k cup','tullys sampler','chocolate kcup','india spice chai','spice tea','nells blend','porcelain cups','newmans own sampler','k cup variety sampler regular','perfect tea','stainless steel travel mug','breakfast tea k cup','dillons peanut brittle','jade sky mug','the ultimate gift','seasonal k-cup','decaf pecan','kcup cocoa','organic pbs','stackable','dark k cup','coffe mugs','green mountain house blend','kcup decaf variety','colombian select','extra bold 10','madison','k cup tree','chocolate donut','national wildlife blend decaf','travel','india spice','t6805','pacific northwest preserve crate','coffee grinder','t4058 kona 10','dezcal descaling cleaner','bella','brittle','keurig b140','all k cups','shortbread','old world','vermont country brunch','peaberry select','white swirl mug','milk','mandarin orange tea','vermont breakfast','pumpkin spice k','b-140','cafe latte','pure maple butter','shade grown organic','dark magic k-cup','sweet lemon','green logo travel mug','k adapter','shortbread cookie','robin','light k cups coffee','highland sugarworks pancake','chocolate coffee k-cup','highland cooperatives','loose leaf tea','tullys house blend decaf','fair trade organic k cups','k cup french vanilla','vacuum','english breakfast tea','my k cup pack','t6792 hazelnut','our blend decaf k cups','extra bold kona','half caff k cups','bodum coffee mugs','french roast k-cups','pumpkin spice ground','vermont apple crate','fair trade gingerbread','k cup decaf sampler','special blend','tully house','coffee house','fair trade coffee','cafe escapes chai','espresso roast','harvest','decaf green tea k-cups','cleancaf','tea brewing','bold k-cup','jason silverman','zhena\'s','sap buckets','refillable filter','k-cup variety','french roast decaf coffee','swirl','cinnamon roll k cup','cc winkle','shade grown coffee','k-cup variety sampler','vermont breakfast basket','medium roast coffee','refillable k cup','oolong tea','k cup chocolate','sweet peach','palopo mug','magic','our blend decaf','fair trade organic k-cups','k cup cocoa','tullys breakfast blend','k cup fair trade select','elite b40','black tea','smoked salmon','kcup tea sampler','single origins sampler','colts bella bark','k cup variety box','fair trade french roast','k cup rain forest nut','smooth','k-cup variety tea','coffe','k-cups boxes','ground coffe in bag','insulated glasses','keurig b-60','mitzis','halfcaff','nutcracker cookie tin','yogurt','shaker','signature coffee','vanilla decaf','emile henry mug','chocolate mugs','english breakfast black tea','k cup regular sampler','brewer cleaner','organic breakfast crate','capresso burr grinder','original','peach coffee k cup','steel travel mug','kcups sampler box','10%','organic blueberry','caramel vanilla k cup','donut k-cup','blueberry tea','fair trade hot chocolate','green mountain coffee mugs','pecan bark','bag size','dark blend','cherry','lake champlain chocolate journeys','celestial seasonings k-cups','enjoy life pitcher','k-cup chocolate','shade','hazelnut cups','southern pecan kcup','president','sauce','sumatra k-cup','english breakfast','organic decaf coffee','rain forest k-cup','tully\'s k-cups decaf','20%','keurig office pro','kona 10','organic pancake','sleepytime tea','vanilla coffee','content','monthly specials','rain forest nut k','signature k-cup tour 6 months','coffee and maple syrup','fair trade organic sumatran reserve','dan lasser','kona k-cups','french vanilla flavored coffee','colts chocolates','coffee thermos','flavored sampler kcup','assorted k cups','dark cocoa','salmon','decaf blends','cioccolato mug set','decaf breakfast blend k-cups','keurig travel tote','vermont apple','cafe chai','kcup tower','better world gift basket','mandarin spice','africa','tully\'s compadre','coffee syrups','all bold','dark roast beans','lake and lodge k','fair trade holiday blend k cup','tully\'s espresso roast','keurig cafe one touch milk frother','t4056','decaffeinated green tea','regular k-cup sampler','sweet ice teas','reusable shopping bag','bamboo','k-cup green tea','olive wood','hot','vermont country k cup','newmans decaf k cup','sp0409','kona medium','colombian especial','green mountain decaf','t-6507','mini b30','keurig k-cup','india','lake champlain chocolates','tully\'s coffee','half-caff k-cup','donut kcup','commercial espresso machine','tullys k-cups','bistro mug','capresso thermal mt500','tully\'s decaf french roast','finca','platinum brewer','kona blend medium','tully evergreen','single cup','el valle','sport mug','diner','tea k','keurig elite b-40 brewer','jade mug','our blend k','reserve coffee','nantucket blend k','fair trade and organic tour','express blend','t-4000','tully\'s coffee house collection','k-cups french vanilla decaf','tullys house collection','muddy creek mugs','newman\'s bold','green mountain colombian','k cup nantucket blend','monthly coffee','k-cup variety sampler regular','sumatran reserve kcups','espresso blend extra bold','mini tote','popular coffees','k cup gift baskets','colombian fair','kcup basket','limited edition coffee','k-cup adapter filter','kcups breakfast blend','perfect peach k-cup','jason','cinnamon donut','spice chai','spring awakening mug','keurig ultimate coffee brewer','earth friendly filters','organic pbs blend','tully\'s house','k cup tea variety','biscotti organic','fair trade raspberry rhapsody','quiet brew','k cup italian roast','double dark diamond','caribou 80','tom','breville keurig','caribou blend k cup','vine','special edition brewer','taste of vermont breakfast basket','drip coffee','ethiopian coffee','maple k cup','process','heritage','olivewood','our','fair trade organic decaf','free trade','keurig water filter','breakfast crate','k cup spice','my k-cup filter','office coffee brewers','bark','fair trade french roast decaf','sweet black tea','oolong','mexican decaf huatusco','eggnog kcup','tully\'s tumbler','sumatra coffee','limited edition the perfect peach','b-30 keurig','vermont country blend k','t-4068','mandarin orange','pea','fair trade organic blend','vanilla nut','fair trade organic shade grown','tullys k cups','b-145','treasures','fair trade rain forest','coffe tour','green stainless tumbler','80 k-cup','flavor tour','jade sky','milk hot chocolate','sky mug','chocolate mocha','t6783 wild mountain blueberry','tullys french roast decaf','caribou decaf k cup','caribou k-cup','half caffeine kcup','organic kcup','treasures gift','celestial english breakfast tea','darkest coffee','k-cup italian roast coffee','pro','organic french roast decaf','emile henri red mug','tullys gift','newmans special blend decaf','green travel mug','filter cup','grind and brew coffee maker','t-6502','60 k-cups','leaf','cc winkle popcorn','seasonal gingerbread','20% more','seasonal spicy eggnog','kenyan aa k cups','extra bold k-cup','espresso maker','full','select origin','flavored sampler decaf','b30 brewer','mondo mug','especial','k-cup flavored sampler','chocolate k-cups','black tea k-cup','keurig b40 brewer','fair trade certified','keurig b40 coffee brewer','k-cup coffee tour','black carousel','organic flavored coffee','pumpkin spice kcup','maple granola','breakfast black tea','darjeeling','breville keurig single cup brewer','fair trade organic mexican','compadre blend','cherries mug','saslaw mug','special decaf','muddy white mug','english breakfast k cup tea','double diamond','seasonal flavor k cups','daybreak morning','french roast extra bold','shade fair','spice','coffee house k cups','dark hot chocolate k cup','taste','chocolate dipped','brewing','holiday green','b-30','vacuum coffee maker','swirl mug','organic house','magnet','country decaf','multigrain organic pancake mix','red mug','12 month tour','ground pumpkin','decaf green tea kcups','k-cup mahogany','gold coffee filter','mandarin orange spice','hot cocoa k','newman bold','flavors of kcups','ground flavored coffee','lover','italian coffee','bold decaf kcup','my k-cup filter refills','kcup refill','k-cup lake and lodge','hazelnut k cup 80','k cup tea sampler','side hill farm','kcup storage basket','k cup refil','cookie tin','seasonal blends','keurig frother','t-4059','lake and lodge kcup','unsweetened black iced tea k-cup','decaf fair trade rain','t-4050','keurig-sized travel mug','todd','pear tea','keurig adapter','kcups our blend','keurig k-cups','6 month','drip','vermont crate','french decaf','decaf k','keurig elite b40 brewer','tully\'s coffee mug','cocoa cup','prices of brewers','extra bold special blend','seasonal flavor tour','thermal french press','80 ct k cups','froth','t4060 sumatran reserve','hazelnut bold','robins chocolate sauce','k-cup hazelnut dark extra bold','vermont kcup','all decaf coffees','vermont country blend k-cup','keurig tote','dan mug','stoneware logo mugs','gmcr travel mug','seasonal k cup tour','fair trade organic pbs blend','bold espresso','devonshire english breakfast tea','moring blend','copper river','t-6003','t-6694','jason silverman jade sky mug','k-cup hot chocolate','caribou blend k-cup','baking','new breville','fair trade autumn harvest blend','tullys k-cup','flavored extra bold','t6508','extra bold kcups','nantucket kcup','de-caf','k cup newman extra bold','autumn seasonal','peach kcup','chocolate biscotti','k-cup bold sampler','kerig brewer warranty','medallions','roll','hot cocoa cups','french roast bold','white filters','hibiscus tea','k cup nut fudge','k cup packs','mocha pot','keurig breville brewer','espresso coffee machine','k-cup vermont country blend decaf','fair trade organic ethiopian yirgacheffe','green tea k','hot cocoa kcup','brew a better world mug','fair trade organic espresso blend','flavored bag','keurig elite b40','coffee with aroma','office keurig','k-cup coffee filter','80 ct k-cup','refill cup','mondo','frond mug','harvest mug','vanilla k cup','k cup coffee flavors','k-cups decaf sampler','scoop n clip','k-cup dark magic extra bold','dark bold roast','t-6505','organic dark roast','keurig coffee brewers','decaffeinated coffee','coffee house collection','french roast k','80 k-cup newmans','lazy susan','80 count coffee','decaf k cup bold','southington ct','14 oz mug','rich coffee','kona cups','better world mug','k cup decaf coffee 80 count','bold kcup','sports','growers','all decaf k cups','my adapter','keurig samplers','kcup tea variety','dark fair trade','k cup summer','fair trade kenyan','citrus','select origin dark chocolates','extra bold decaf k-cup','forest','manzanillo','red raspberry','homann','dan lasser harvest mug','magnetic clips','french vanilla decaf kcup','b-200','english black','keurig coffee carousel','kcup orange tea','extra bold k-cups','extra bold kona blend','winding stream','city roast','monthly k cup','compadre','rs106','french roast decaf k-cup','celestial seasonings tea k-cups','customer ratings','caramel decaf','k cups heifer hope blend','bodum tall','rain forest nut coffee k cups','caramel cream k-cup','variety k','p umpkin spice','double black','k-cup southern pecan','finca dos','flavored k','k-cup flavored variety','g','k coffees','tullys extra bold','newmans special blend extra bold','dark diamond','keurig hot cocoa','decaf coffee pods','t-6992','kcups newmans organics','organic cappuccino','steel mugs','medium blend coffee','cup carousel','six month','keurig b30 mini travel tote','half-caff k-cups','french red','keurig platinum b70','pumpkin kcup','extra bold decaf k cups','chocolate hot cocoa','bialetti','olive scoop','kcup seasonal coffees','caramel cream','caribou kcups','black tea unsweetened','zinger tea','k-cup dark chocolate hot cocoa','80 count k','10% kona blend','k cup chamomile tea','kit','decaf and regular blend','tully french','pbs k-cup','medium roast beans','fair trade house','carouse l','kcup dark magic decaf','caribou blend decaf','refill pack','pumpkin flavor','newman organic coffee','organic french decaf','mondo mug set','t-6602','t-4057','t-6994','t-6752','olive coffee scoop','t-6700','caribou k-cups','gmcr diner mug','hazelnut dark k cup','k-cup fair trade wild mountain blueberry','english breakfast black','olivewood scoop','tully decafe kcup','fair trade organic vanilla cream','dark magic espresso bold','clip scoop','kcup mocha nut fudge','coffee k-cups','kcup variety sampler','k-cup italian','lemon buttermilk cake mix','all teas','keurig hazelnut','caribou coffee mahogany','newmans special extra bold','gmcr insulated carafe','logo grinder','share price','k cup variety sampler flavored','list coffee flavors','portion ground packages','purpose','to go mug','breakfast blend decaf kcup','fair trade pumpkin','keurig single brewers','stainless steel coffee','kcups autumn harvest blend','caribou coffee sumatra','bold hazelnut k-cup','flavored decaffeinated','brewing a better world fund','seasonal k coffee tour','bold magic','breakfast blend k','fair trade wild blueberry','art','tullys extra bold french roast','coffee samplers kcups','newman owns nell medium roast','serving','manzanillo mugs','caribou breakfast blend','fto french roast','dark chocolate k-cup','institutional','decaf vanilla k-cup','yoga','robust','gypsy king chai','organic k cup sumatran extra bold','k cup bold sampler','k-cup regular variety','wood animals','south american','b30 manual','is the coffee shade grown','davids','keurig platinum b70 k cup single-cup brewer','ciat','tall insulated glass','native energy','wood carvings','ngo\'s','wild mountain blueberry k cup','fair trade organic espresso','crowther','temperature','k-cup flavored coffee sampler','transportation','extra bold sumatran reserve k-cup','fair trade chocolate','green scoop','mccreary','other brands','k cup regular coffees','my','mardy','social responsibility report 2008','kcup kenyan','half caff k','dark blend k cup','very light coffees','fair trade peach','pineapple','songbird','caffeinated teas','blackthorne','grahams','k-cup kona 10% blend extra bold','bergamot','stewardship program','deborah lisman','caribou blend decaf k-cup','flle','address 3','sunrise','nissan carafe','chocolate love','gmcr grinder','stainless steel scoop','caribou coffee french roast','my delivery','cone','newman blend','hot coffee recipes','green mountain mug','liquid sugar','k cup variety sampler tea','better brew','coffe grinder','estate sampler','k-cup celestial','holly','fair trade summer celebration','ft106t','net sales','french roast by tullys','domestic grant','united nations','k-cup breakfast','k-cup double black','brewer with grinder','k cup coffee sampler','k-cup lemon tea','tamp','flavored variety kcups','sustainability team','plastic tumbler','fair trade perfect peach','6','event donations','organic vanilla coffee','t6720 fair trade island coconut','green mountain coffe mug','indian coffee','k cup raspberry tea','kcups medium roast','organic sumatra bold','fair trade organic coffee','2005 report','2005 csr report','k-cup newmans special blend extra bold','b70 brew strength','decaf gift baskets','passion','deer','paper bag','#t6502','#t6503','world cocoa','hot beverage cups','k-cup medium','my bill','fran','newmans own french roast','keurig manual','sara lee','keurig plastic travel mug','newmans extra bold decaf','pick','caribou coffee cup','keurig one cup brewer','certified organic coffee','return address','extra bold 10% kona blend','little acidity','k cup coffee medium','kcup caramel','k cup swiss water','tully\'s italian','earth','k cup patent','flavored organic k-cup coffee','double certified','kflle','kcup wild blueberry','extra bold intense dark magic','i want to place an order','c store','health insurance offerings','k cup evergreen','10-q','thriving workplace','single creamers','extra bold 10% kona coffee blend','dark chocolate kcup','#t6501','k-cup patent number','q2 earnings','keurig company','k-cup fair trade espresso blend extra bold','lb','t-6503','legend','rare','kcup delivery','making iced coffee','keurig my k cup','k-cup fair trade organic sumatran reserve','green mountain coffee tully\'s','how many sales per day','artificial sweetener','day','mail business','decaf african','coffe of the month','quality statement','keurig-sized','caribou dark roast','keurig sale','nasdaq gmcr','objectives','coffee essentials gift','love my keurig','other drinks','k-cup caribou coffee colombian','conventional','fair trade k-cups pumpkin','my-kcup','kcup coffee filter','coffee gifts','k-cup reusable coffee filter','value chain','organic decaf breakfast','#2','keurig b-70','black mug','briefcase','letter of intent','coffee growing countries','kraft','k-cup tour','chalk mug','renewable','funding','my k filter','see my order','caribou coffee daybreak morning blend','k-cup caribou french roast','hurricane','k-cup caribou colombian','@gmcr.com','coffee tamper','rex','net income','k cup lazy susan','issues of financial statements','fair trade organic colombian','k kcup tea','t-6802','k-cup caribou coffee caribou blend decaf','k-cup breakfast tea','all hot chocolate','out of stock','k-cup refil','t-6720','garden','k carousel','medium amber','kcup 60 pack','scott','t-7602','t-7792','t-6783','bistro','caribou blend natural decaf coffee','biddeford maine','caribou flavored coffee','dp','k kcup samplers','mill','company governance','keurig cocoa','current news','k cup wicked winter blend extra bold','leadership','keurig b30 personal brew','green mountain paper cups','cake up','keurig tree','knit','extra bold variety pack','my pack','#t6504','k cup order form','ethnic','k cup coffee newmans','nonorganic','j cup','#t6003','dark roast sumatran','fair trade dark roast','keurig k cup filter','using k cups','about cafe express','keurig flavors','kcup extra bold sampler','fair trade organic better world cocoa','my-k','web','vermont syrup','k-cup environmental','removable 48-oz water reservoir','fair trade c','great place to work','hold','coffee accessories','888-try-gmcr','k cup ejection','keurig reusable','keurig kona','k-cup single filter','k cup coffee club','k cup travel mug','keurig one cup','k-cup mandarin orange spice tea','k cup coffee bold','keurig gold cup','grade k cup double chocolate hot cocoa','keurig folgers','decaf single','k cup mugs','no longer','keurig variety pack','smoked coffee','organic decaffeinated','fair tradepumpkin spice','coffee and tea basket','patty','t-6501','coffeemakers cleaner','keurig 60','c c winkle','vegetarian','bodum 2 oz mug','super automatic','organic basket','pennsylvania','t-4060','600','flavored c cups','kcup black tea','asphalt road mix','coffee market','lace cookies','french vanilla k','k cup bold flavored variety','meaning of fair trade','fair trade blueberry','dark k-cup','poetry','green k cup','aids','k-cup assorted flavor sampler','coffee hazelnut k-cups','k cup teas lemon','disaster relief','keurig one cup coffee makers','organic certification','not my order','fair trade 2007','doka','the new keurig classic single-cup brewer','hunger','keurig for the office','10 cup espresso maker','coffee strength','myorder','woburn','keurig single-cup commercial brewer','labor employment','political','driving jobs','policy on employee misconduct','k cup coffee extra bold','green mountain ground','fair trade act');
/* $Revision: 3828 $
 *
 */

if(typeof(_sli_init )!='object'){var _sli_init=new Array();}
if(typeof(sli_init )!='function'){function sli_init(){ for(var x=0;x<_sli_init.length;x++) _sli_init[x]();}}
if(typeof(asPhrases)!='object'){ var asPhrases = new Array(); }
if(typeof(__SLI_customisations)!='object'){var __SLI_customisations = new Object();}
if(typeof(__SLI_ClientDefaults)!='object'){ var __SLI_ClientDefaults=[]; }
if(typeof(__SLI_validSearchBoxes)!='object'){ var __SLI_validSearchBoxes = new Array(); }
if(typeof(__SLI_asug_used_flag)!='object'){ var __SLI_asug_used_flag = false; }
if(typeof(__SLI_width)!='object'){ var __SLI_width = 0; }
if(typeof(sli_targeturl)!='object'){ var sli_targeturl = ""; }


    __AutoComplete = new Object(); //namespace...
    __AutoComplete_mouseMoved=false;

    // Basic UA detection
    isIE = document.all ? true : false;
    isGecko = navigator.userAgent.toLowerCase().indexOf('gecko') != -1;
    isOpera = navigator.userAgent.toLowerCase().indexOf('opera') != -1;

    /* defaults and options */

    var __SLI_ApplicationName = 'AutoSuggest';
        __SLI_customisations[ 'AutoSuggest' ] =
                {
                    'ShowBrandingFooter' : true
                    ,
                    'TextBoxIDPrefix' : 'sli_search_'
                    ,
                    'BrandingFooterImagePath' : 'http://assets.resultspage.com/autosuggest/sli_systems-powered_150_15.gif'
                    ,
                    'BrandingFooterTitleTooltip' : 'AutoSuggest Powered by SLI Systems'
                    ,
                    'DropListMinWidth' : 150
                    ,
                    'MaxListItems' : 10
                    ,
                    'Alignment' : true
                    ,
                    'TextBoxIDCustom' : []
                    ,
                    'ValidSearchBoxes' : false 
                    ,
                    'IE6SelectBox' : false 
                    ,
                    'IE6SelectBoxPadding' : 0
                    ,
                    'TargetURL' : ''
                    ,
                    'IframeAlignment' : false
                    ,
                    'AlignmentBorderBug' : false
                    ,
                    'IE6OnFocus' : false
                };
    /* 0 = keyname, 1 = value */
    for( defaultValuePair in __SLI_ClientDefaults )
    {
        __SLI_customisations[__SLI_ApplicationName][__SLI_ClientDefaults[defaultValuePair][0]]=__SLI_ClientDefaults[defaultValuePair][1];
    }

    /* pre-fetch branding footer image if being used...
     */
    if( __SLI_customisations[ __SLI_ApplicationName ][ 'ShowBrandingFooter' ] )
    {
        
        if(location.protocol == "https:")
        {
            __SLI_customisations[ __SLI_ApplicationName ][ 'BrandingFooterImagePath' ] = __SLI_customisations[ __SLI_ApplicationName ][ 'BrandingFooterImagePath' ].replace(/http:/i, 'https:');
        }
    
        var __AutoCompleteBranding = new Image();
        __AutoCompleteBranding.src=__SLI_customisations[ __SLI_ApplicationName ][ 'BrandingFooterImagePath' ];
    }


    function AutoComplete_init()
    {
        if(!isOpera)
        {
            var oldonresize=function(){};
            if(typeof(window.onresize)=='function')
                oldonresize = window.onresize;//play nicely with other people's toys
            window.onresize= function(){ oldonresize(); AutoComplete_HideAll(); AutoComplete_Create( asPhrases ); }

            AutoComplete_Create( asPhrases );
            
            var els = document.getElementsByTagName('input');
            if(els)
            {
               for ( i = 0; i < els.length; i++ )
               {
                  if(els[i].name == "asug")
                  {
                     els[i].disabled = true;
                  }
               }
            }
        }
    }




    /**
    * Attachs the autocomplete object to a form element. Sets
    * onkeypress event on the form element.
    *
    * @param string formElement Name of form element to attach to
    * @param array  data        Array of strings of which to use as the autocomplete data
    */
    //function AutoComplete_Create (id, data)
    /*
     * iterate over 'sli_search_*' assumes one or more search boxes numbered from 1...
    */
    function AutoComplete_Create( data )
    {
        var idx=1, e, id, searchBoxPrefix=__SLI_customisations[ __SLI_ApplicationName ][ 'TextBoxIDPrefix' ];
        while( e = document.getElementById(searchBoxPrefix+idx) )
        {
            AutoComplete_AttachHandlers(e, data);
            if( __SLI_customisations[ __SLI_ApplicationName ][ 'ValidSearchBoxes' ] )
            {
                __SLI_validSearchBoxes.push(searchBoxPrefix+idx);
            }
            idx++;
        }
        
        
        //this array comes from the customised list
        var otherTextBoxIdList = __SLI_customisations[ __SLI_ApplicationName ][ 'TextBoxIDCustom' ];
        if( otherTextBoxIdList)
        {
            for(idx=0;idx<otherTextBoxIdList.length;idx++)
            {
                e = document.getElementById(otherTextBoxIdList[idx]);
                if(e)
				{
					if( __SLI_customisations[ __SLI_ApplicationName ][ 'ValidSearchBoxes' ] )
                	{
	                    __SLI_validSearchBoxes.push( otherTextBoxIdList[idx] );
                	}
					AutoComplete_AttachHandlers(e, data);
				}
            }
        }
        
    } 

    function AutoComplete_AttachHandlers(e, data){
        var iframe,id;
        id=e.id;


        __AutoComplete[id] = {'data':data,
                              'isVisible':false,
                              'element':document.getElementById(id),
                              'dropdown':null,
                              'highlighted':null};

        __AutoComplete[id]['element'].setAttribute('autocomplete', 'off');
        __AutoComplete[id]['element'].onkeydown = function(e) {if (!e) e = window.event; return AutoComplete_KeyDown(this.getAttribute('id'), e);}
        __AutoComplete[id]['element'].onkeyup = function(e) {if (!e) e = window.event; return AutoComplete_KeyUp(this.getAttribute('id'), e);}
        // The function call on the next line was changed by Andrew Grieve April 2008
        __AutoComplete[id]['element'].onkeypress = function(e) {if (!e) e = window.event; return AutoComplete_KeyPress(this.getAttribute('id'), e);}
        __AutoComplete[id]['element'].onclick = function(e)
        {
            if( __SLI_customisations[ __SLI_ApplicationName ][ 'IE6OnFocus' ] )
            {
                __AutoComplete[id]['element'].focus();
            }
            if (!e) e = window.event; e.cancelBubble = true; e.returnValue = false;
        }



        // Hides the dropdowns when document clicked
        var docClick = function()
        {
            if( __SLI_customisations[ __SLI_ApplicationName ][ 'ValidSearchBoxes' ] )
            {
               for(var i=0; i < __SLI_validSearchBoxes.length; i++)
               {
                   if(document.getElementById(__SLI_validSearchBoxes[i]))
                   {
                       AutoComplete_HideDropdown(__SLI_validSearchBoxes[i]);
                   }
               }
            }
            else
            {
                for (id in __AutoComplete)
                {
                   AutoComplete_HideDropdown(id);
                }
            }
        }

        if (document.addEventListener) {
            document.addEventListener('click', docClick, false);
        } else if (document.attachEvent) {
            document.attachEvent('onclick', docClick, false);
        }


        // Max number of items shown at once
        if (arguments[2] != null) {
            __AutoComplete[id]['maxitems'] = arguments[2];
            __AutoComplete[id]['firstItemShowing'] = 0;
            __AutoComplete[id]['lastItemShowing'] = arguments[2] - 1;
        }

        AutoComplete_CreateDropdown(id);

        // Prevent select dropdowns showing thru
        if (isIE) {
            iframe = document.createElement('iframe');
            __AutoComplete[id]['iframe'] = iframe;
                iframe.id = id +'_iframe';
                iframe.style.position = 'absolute';
                iframe.style.top = '0';
                iframe.style.left = '0';
                iframe.style.width = '0px';
                iframe.style.height = '0px';
                iframe.style.zIndex = '98';
                iframe.style.visibility = 'hidden';
                
                if(location.protocol == "https:")
                {
                   iframe.src = 'https://assets.resultspage.com/autosuggest/blank.html';
                }
                
                if( __SLI_customisations[ __SLI_ApplicationName ][ 'IE6SelectBox' ] )
                {
                  iframe.style.width = __SLI_width  + __SLI_customisations[ __SLI_ApplicationName ][ 'IE6SelectBoxPadding'];
                }

            if( __SLI_customisations[ __SLI_ApplicationName ][ 'IframeAlignment' ] )
            {
                document.body.insertBefore( iframe );
            }
            else
            {
                __AutoComplete[id]['element'].parentNode.insertBefore( iframe, __AutoComplete[id]['element'] );
            }
        }
    }

    /**
    * Creates the dropdown layer
    *
    * @param string id The form elements id. Used to identify the correct dropdown.
    */
    function AutoComplete_CreateDropdown(id)
    {
        var theSearchbox = __AutoComplete[id]['element'];
        var theDropDown;
        var left_top = AutoComplete_getPos( theSearchbox );
        var left  = left_top[0];
        var top   = left_top[1] + theSearchbox.offsetHeight;
        var width = theSearchbox.offsetWidth;

        if ( width < __SLI_customisations[ __SLI_ApplicationName ][ 'DropListMinWidth' ] )
        {
            width = __SLI_customisations[ __SLI_ApplicationName ][ 'DropListMinWidth' ];
        }

        theDropDown = document.createElement('div');
        theDropDown.className = 'autocomplete'; // Don't use setAttribute()


        if(__SLI_customisations[ __SLI_ApplicationName ][ 'Alignment' ] == true && document.body)
        {
            theDropDown.style.position = 'absolute';
            document.body.insertBefore(theDropDown, document.body.nextSibling);
            
            // Position it
            theDropDown.style.visibility = 'hidden';
            theDropDown.style.left       = left + 'px';
            theDropDown.style.top        = top + 'px';
            theDropDown.style.width      = width + 'px';
            theDropDown.style.zIndex     = '99999';
        }
        else if(__SLI_customisations[ __SLI_ApplicationName ][ 'Alignment' ] == "offsetrelative" && document.body)
        {
          theSearchbox.parentNode.insertBefore(theDropDown, theSearchbox);
          // Position it
          if(sli_getStyle(theSearchbox.offsetParent, 'position') != "absolute")
          {
            theSearchbox.offsetParent.style.position = 'relative';
          }
          theDropDown.style.position = 'absolute';
          theDropDown.style.left = (theSearchbox.offsetLeft) + 'px';
          theDropDown.style.top = (theSearchbox.offsetTop + theSearchbox.offsetHeight) + 'px';
          theDropDown.style.width = (theSearchbox.clientWidth) + 'px';
          theDropDown.style.visibility = 'hidden';
          theDropDown.style.zIndex     = '99999999';
        }
        else
        {
            theSearchbox.parentNode.insertBefore(theDropDown, theSearchbox);
            // Position it
            theDropDown.style.visibility = 'hidden';
            theDropDown.style.left       = left + 'px';
            theDropDown.style.top        = top + 'px';
            theDropDown.style.width      = width + 'px';
            theDropDown.style.zIndex     = '99999';
        }
        

        __AutoComplete[id]['dropdown'] = theDropDown;
        __SLI_width = width;
    }

    function /* array [ left, top ] */ AutoComplete_getPos( obj )
    {
        var curleft = curtop = 0;
        var sli_flag = 0;

        if (obj.offsetParent)
        {
           do
           {
              if ( __SLI_customisations[ __SLI_ApplicationName ][ 'AlignmentBorderBug' ] )
              {         
                
                if(sli_flag == 1)
                {
                    var clientTop = (obj.offsetHeight - obj.clientHeight) / 2;
                    curtop += clientTop;

                    var clientLeft = (obj.offsetWidth - obj.clientWidth) / 2;
                    curleft += clientLeft;
                }
                sli_flag = 1;
              }
           
              curleft += obj.offsetLeft;
              curtop += obj.offsetTop;
           }
           while (obj = obj.offsetParent);
        }
        return [curleft,curtop];
    }

    /**
    * Shows the dropdown layer
    *
    * @param string id The form elements id. Used to identify the correct dropdown.
    */
    function AutoComplete_ShowDropdown(id)
    {

        AutoComplete_HideAll();



        var value = __AutoComplete[id]['element'].value;
        var toDisplay = new Array();
        var newDiv    = null;
        var text      = null;
        var numItems  = __AutoComplete[id]['dropdown'].childNodes.length;

        __AutoComplete_mouseMoved=false;
        // SLI Code Modification - Start - Andrew Grieve April 08
        // Trim the textbox so that if is starts with a space then the feature will still work
        //value = value.replace(/^\s+|\s+$/g,"");
        value = value.replace(/^\s+/g,"");

        if(value.length == "")
        {
            // If Textbox length is nothing (after the trim) then don't show dropdown.
            return;
        }
        // SLI Code Modification - End

        // Remove all child nodes from dropdown
        while (__AutoComplete[id]['dropdown'].childNodes.length > 0) {
            __AutoComplete[id]['dropdown'].removeChild(__AutoComplete[id]['dropdown'].childNodes[0]);
        }


        var count=0;
        // Go thru data searching for matches
        for (i=0; i<__AutoComplete[id]['data'].length; ++i)
        {
            // SLI Code Modification - Start - Andrew Grieve April 08 - Added lower casing
            if (__AutoComplete[id]['data'][i].substr(0, value.length).toLowerCase() == value.toLowerCase())
            {
                // SLI Code Modification - End
                toDisplay[toDisplay.length] = __AutoComplete[id]['data'][i];
                count++;
                /* how many to display? */
                if(count == __SLI_customisations['AutoSuggest']['MaxListItems'] ) /* Code inserted to keep list to a maximum of 10 values (was 20 or 30) */
                {
                    break;
                }
            }
        }

        // No matches?
        if (toDisplay.length == 0) {
            AutoComplete_HideDropdown(id);
            return;
        }



        // Add data to the dropdown layer
        for (i=0; i<toDisplay.length; ++i) {
            newDiv = document.createElement('div');
            newDiv.className = 'autocomplete_item'; // Don't use setAttribute()
            newDiv.setAttribute('id', 'autocomplete_item_' + i);
            newDiv.setAttribute('index', i);
            newDiv.style.zIndex = '99999';

             // Scrollbars are on display ?
            if (toDisplay.length > __AutoComplete[id]['maxitems'] && navigator.userAgent.indexOf('MSIE') == -1) {
                newDiv.style.width = __AutoComplete[id]['element'].offsetWidth - 22 + 'px';
            }

            newDiv.onmouseover =
        function()
        {
            if( __AutoComplete_mouseMoved )
                AutoComplete_HighlightItem(__AutoComplete[id]['element'].getAttribute('id'), this.getAttribute('index'));
        };

            newDiv.onclick     =    function()
                                    {
                                    	  __SLI_asug_used_flag = true;
                                                                           
                                        AutoComplete_SetValue(__AutoComplete[id]['element'].getAttribute('id'));
                                        AutoComplete_HideDropdown(__AutoComplete[id]['element'].getAttribute('id'));
                                        AutoComplete_submitForm(id);
                                    }



            text   = document.createTextNode(toDisplay[i]);
            newDiv.appendChild(text);
            newDiv.title='Search for ' + toDisplay[i];

            /* ellipsis for IE only */
            if( isIE )
            {
                newDiv.style.textOverflow = 'ellipsis';
                newDiv.style.width = '100%';
                newDiv.style.whiteSpace = 'nowrap';
                newDiv.style.overflow = 'hidden';

            }
            __AutoComplete[id]['dropdown'].appendChild(newDiv);
        }
        /*
         * append DIV containing footer branding...
         */
        if(__SLI_customisations['AutoSuggest']['ShowBrandingFooter'])
        {
            i = toDisplay.length;
            newDiv = document.createElement('div');
            newDiv.className = 'autocomplete_footer'; // Don't use setAttribute()
            newDiv.setAttribute('id', 'autocomplete_item_' + i);
            newDiv.setAttribute('index', i);
            newDiv.style.zIndex = '99999';
            newDiv.innerHTML = '<a href="http://www.sli-systems.com/powered-by.php" title="' +
                                __SLI_customisations[ __SLI_ApplicationName ][ 'BrandingFooterTitleTooltip' ] +
                                '"><img class="autocomplete_footer_branding" src="'+__AutoCompleteBranding.src+'" /></a>';

            __AutoComplete[id]['dropdown'].appendChild(newDiv);
        }


        // Too many items?
        if (toDisplay.length > __AutoComplete[id]['maxitems']) {
            __AutoComplete[id]['dropdown'].style.height = (__AutoComplete[id]['maxitems'] * 15) + 2 + 'px';

        } else {
            __AutoComplete[id]['dropdown'].style.height = '';
        }


        /**
        * Set left/top in case of document movement/scroll/window resize etc
        */
        if(__SLI_customisations[ __SLI_ApplicationName ][ 'Alignment' ] == "true" || __SLI_customisations[ __SLI_ApplicationName ][ 'Alignment' ] == "false")
        {
            var left_top = AutoComplete_getPos( __AutoComplete[id]['element'] );
            __AutoComplete[id]['dropdown'].style.left = left_top[0];
            __AutoComplete[id]['dropdown'].style.top  = left_top[1] + __AutoComplete[id]['element'].offsetHeight;
        }


        // Show the iframe for IE
        if (isIE) {
            
            if(!__SLI_customisations[ __SLI_ApplicationName ][ 'Alignment' ] == true)
            {
               __AutoComplete[id]['iframe'].style.width  = __AutoComplete[id]['dropdown'].offsetWidth;
            }
            
            
            __AutoComplete[id]['iframe'].style.top    = __AutoComplete[id]['dropdown'].style.top;
            __AutoComplete[id]['iframe'].style.left   = __AutoComplete[id]['dropdown'].style.left;
            __AutoComplete[id]['iframe'].style.height = __AutoComplete[id]['dropdown'].offsetHeight;

            __AutoComplete[id]['iframe'].style.visibility = 'visible';
        }

    e =  __AutoComplete[id]['dropdown'];

    e.onmousemove =
        function()
        {
            if(!__AutoComplete_mouseMoved){__AutoComplete_mouseMoved=true;}
            this.onmousemove = null;
        }

        // Show dropdown
        if (!__AutoComplete[id]['isVisible']) {
            __AutoComplete[id]['dropdown'].style.visibility = 'visible';
            __AutoComplete[id]['isVisible'] = true;
        }


        // If now showing less items than before, reset the highlighted value
        if (__AutoComplete[id]['dropdown'].childNodes.length != numItems) {
            __AutoComplete[id]['highlighted'] = null;
        }
    }



    /**
    * Hides the dropdown layer
    *
    * @param string id The form elements id. Used to identify the correct dropdown.
    */
    function AutoComplete_HideDropdown(id)
    {
        if (__AutoComplete[id]['iframe'])
        {
            __AutoComplete[id]['iframe'].style.visibility = 'hidden';
        }
        
        if (__AutoComplete[id]['dropdown'])
        {
            __AutoComplete[id]['dropdown'].style.visibility = 'hidden';
        }

        __AutoComplete[id]['highlighted'] = null;
        __AutoComplete[id]['isVisible']   = false;
    }


    /**
    * Hides all dropdowns
    */
    function AutoComplete_HideAll()
    {
         if( __SLI_customisations[ __SLI_ApplicationName ][ 'ValidSearchBoxes' ] )
         {
               for(var i=0; i < __SLI_validSearchBoxes.length; i++)
               {
                   if(document.getElementById(__SLI_validSearchBoxes[i]))
                   {
                       AutoComplete_HideDropdown(__SLI_validSearchBoxes[i]);
                   }
               }
         }
         else
         {
                for (id in __AutoComplete)
                {
                   AutoComplete_HideDropdown(id);
                }
         }
    }


    /**
    * Highlights a specific item
    *
    * @param string id    The form elements id. Used to identify the correct dropdown.
    * @param int    index The index of the element in the dropdown to highlight
    */
    function AutoComplete_HighlightItem(id, index) // mouseover, index is the list element index, zero-based
    {
        if (__AutoComplete[id]['dropdown'].childNodes[index]) {
            for (var i=0; i<__AutoComplete[id]['dropdown'].childNodes.length; ++i) {
                if (__AutoComplete[id]['dropdown'].childNodes[i].className == 'autocomplete_item_highlighted') {
                    __AutoComplete[id]['dropdown'].childNodes[i].className = 'autocomplete_item';
                }
            }

            __AutoComplete[id]['dropdown'].childNodes[index].className = 'autocomplete_item_highlighted';
            __AutoComplete[id]['highlighted'] = index;

            //also see below...
            //__AutoComplete[id]['element'].value = __AutoComplete[id]['dropdown'].childNodes[index].innerHTML;
            //AutoComplete_SetValue(id);
        }
    }


    /**
    * Highlights the menu item with the given index
    *
    * @param string id    The form elements id. Used to identify the correct dropdown.
    * @param int    index The index of the element in the dropdown to highlight
    */
    function AutoComplete_Highlight(id, index) // keyboard up/down - index is the direction of travel, 1==down,-1=up
    {
        var childNodes = __AutoComplete[id]['dropdown'].childNodes;
        if(childNodes.length)
        {
	        var lastItem = ( ( childNodes[ childNodes.length - 1 ].className != 'autocomplete_footer' ) ? childNodes.length - 1 : childNodes.length - 2 );

            // Out of bounds checking
            //if (index == 1 && __AutoComplete[id]['highlighted'] == __AutoComplete[id]['dropdown'].childNodes.length - 1) {
            if (index == 1 && __AutoComplete[id]['highlighted'] == lastItem ) {
                childNodes[__AutoComplete[id]['highlighted']].className = 'autocomplete_item';
                __AutoComplete[id]['highlighted'] = null;

            } else if (index == -1 && __AutoComplete[id]['highlighted'] == 0) {
                childNodes[0].className = 'autocomplete_item';
                __AutoComplete[id]['highlighted'] = lastItem;
                index = 0;//hack!
            }

            // Nothing highlighted at the moment
            if (__AutoComplete[id]['highlighted'] == null) {

                childNodes[0].className = 'autocomplete_item_highlighted';
                __AutoComplete[id]['highlighted'] = 0;
                newIndex = 0;
                
            } else {

                if (childNodes[__AutoComplete[id]['highlighted']]) {
                
                    childNodes[__AutoComplete[id]['highlighted']].className = 'autocomplete_item';
                }

                var newIndex = parseInt( __AutoComplete[id]['highlighted'] ) + parseInt(index);

                if (childNodes[newIndex]) {

                    childNodes[newIndex].className = 'autocomplete_item_highlighted';

                    __AutoComplete[id]['highlighted'] = newIndex;
                }
            }

            //populate textbox with currently highlighted term...
            //__AutoComplete[id]['element'].value = __AutoComplete[id]['dropdown'].childNodes[newIndex].innerHTML;
            AutoComplete_SetValue(id);
        }
    }


    /**
    * Sets the input to a given value
    *
    * @param string id    The form elements id. Used to identify the correct dropdown.
    */
    function AutoComplete_SetValue(id)
    {
        __AutoComplete[id]['element'].value = __AutoComplete[id]['dropdown'].childNodes[__AutoComplete[id]['highlighted']].innerHTML.replace(/&amp;/, "&");
    }


    /**
    * Checks if the dropdown needs scrolling
    *
    * @param string id    The form elements id. Used to identify the correct dropdown.
    */
    function AutoComplete_ScrollCheck(id)
    {
        // Scroll down, or wrapping around from scroll up
        if (__AutoComplete[id]['highlighted'] > __AutoComplete[id]['lastItemShowing']) {
            __AutoComplete[id]['firstItemShowing'] = __AutoComplete[id]['highlighted'] - (__AutoComplete[id]['maxitems'] - 1);
            __AutoComplete[id]['lastItemShowing']  = __AutoComplete[id]['highlighted'];
        }

        // Scroll up, or wrapping around from scroll down
        if (__AutoComplete[id]['highlighted'] < __AutoComplete[id]['firstItemShowing']) {
            __AutoComplete[id]['firstItemShowing'] = __AutoComplete[id]['highlighted'];
            __AutoComplete[id]['lastItemShowing']  = __AutoComplete[id]['highlighted'] + (__AutoComplete[id]['maxitems'] - 1);
        }

        __AutoComplete[id]['dropdown'].scrollTop = __AutoComplete[id]['firstItemShowing'] * 15;
    }


    /**
    * Function which handles the keypress event
    *
    * @param string id    The form elements id. Used to identify the correct dropdown.
    */
    function AutoComplete_KeyDown(id, e)
    {
        var result = true;

       var event;
       event = e;
       if(!event) event = window.event;

        var keyCode = event.keyCode;

        switch (keyCode) {

            // Return/Enter
            case 13:
                if (__AutoComplete[id]['highlighted'] != null) {
                    AutoComplete_SetValue(id);
                    AutoComplete_HideDropdown(id);
					
                    __SLI_asug_used_flag = true;
					
                    if( e = __AutoComplete[id]['element'].form['asug'] )
                    {
                        
                        e.disabled=false;
                        e.value = __AutoComplete[id]['asug'];
                    }

                }

                result = AutoComplete_submitForm(id);

                break;

            // Escape
            case 27:
                AutoComplete_HideDropdown(id);
                event.returnValue = false;
                event.cancelBubble = true;
                break;

            // Up arrow
            case 38:
                if (!__AutoComplete[id]['isVisible']) {
                    AutoComplete_ShowDropdown(id);
                }

                AutoComplete_Highlight(id, -1);
                AutoComplete_ScrollCheck(id, -1);
                
                if( e = __AutoComplete[id]['element'].form['asug'] )
                {
                   e.disabled=false;
                   e.value = __AutoComplete[id]['asug'];
                }

                                
                result = false;
                break;

            // Tab
            case 9:
                if (__AutoComplete[id]['isVisible']) {
                    AutoComplete_HideDropdown(id);
                }
                return;

            // Down arrow
            case 40:

                if (!__AutoComplete[id]['isVisible']) {
                    AutoComplete_ShowDropdown(id);
                }

                AutoComplete_Highlight(id, 1);
                //AutoComplete_ScrollCheck(id, 1);

                if( e = __AutoComplete[id]['element'].form['asug'] )
                {
                   e.disabled=false;
                   e.value = __AutoComplete[id]['asug'];
                }

                result = false;
                break;
        }
        return result;
    }


    /**
    * Function which handles the keyup event
    *
    * @param string id    The form elements id. Used to identify the correct dropdown.
    */
    function AutoComplete_KeyUp(id, e)
    {
       var event;
       event = e;
       if(!event) event = window.event;

        var keyCode = event.keyCode;

        switch (keyCode) {
            case 13:
                event.returnValue = false;
                event.cancelBubble = true;
                
                break;

            case 27:
                AutoComplete_HideDropdown(id);
                event.returnValue = false;
                event.cancelBubble = true;
                break;

            case 38:
            case 40:
                return false;
                break;

            default:
                AutoComplete_ShowDropdown(id);
                
                __AutoComplete[id]['asug']=__AutoComplete[id]['element'].value;

                if( e = __AutoComplete[id]['element'].form['asug'] )
                {
                   e.disabled=true;
                   e.value = "";
                }  
                
                break;
        }
    }

    /**
    * Function which handles the keypress event
    * This function added April 2008 by Andrew Grieve
    *
    * @param string id    The form elements id. Used to identify the correct dropdown.
    */

    // SLI Code Modification - Start - Andrew Grieve April 08
    function AutoComplete_KeyPress(id, e)
    {
        var event = e;
        if(!event) event = window.event;
        var keyCode = event.keyCode;

        if (keyCode == 13 && isGecko || isOpera)
        {
            return false;
        }
        
        if( __SLI_customisations[ __SLI_ApplicationName ][ 'TargetURL' ] )
        {
            if (keyCode == 13 && isIE)
            {
                return false;
            }
        }
        
    }
    // SLI Code Modification - End

    /**
    * Returns whether the dropdown is visible
    *
    * @param string id    The form elements id. Used to identify the correct dropdown.
    */
    function AutoComplete_isVisible(id)
    {
        return __AutoComplete[id]['dropdown'].style.visibility == 'visible';
    }

    function AutoComplete_submitForm(id)
    {
        var e, f, result=true;
        if( f = __AutoComplete[id]['element'].form )
        {
            if( __AutoComplete[id]['element'].value != '' )
            {
            	if(__SLI_asug_used_flag == true)
            	{
                   if( e = f['asug'])
                   {
                      e.value = __AutoComplete[id]['asug'];
                      e.disabled=false;
                   }
                }
                
                if( __SLI_customisations[ __SLI_ApplicationName ][ 'TargetURL' ] )
                {
                	asugvar = "";
                	if(__SLI_asug_used_flag == true)
                	{
                	  asugvar = '&asug=' + __AutoComplete[id]['asug'];
                  	}
                    
                    sliRegex = /resultsdemo\.com/;
                    if(sliRegExArray = sliRegex.exec(document.domain))
                    {
                    	sliRegex = /^http:\/\/(.*)\//;
                    	sliTargetDomain = sliRegex.exec(__SLI_customisations[__SLI_ApplicationName ][ 'TargetURL' ]);
                    	__SLI_customisations[__SLI_ApplicationName ][ 'TargetURL' ] = __SLI_customisations[__SLI_ApplicationName ][ 'TargetURL' ].replace(sliTargetDomain[1], document.domain);
                    }
                    
                	document.location.href = __SLI_customisations[__SLI_ApplicationName ][ 'TargetURL' ] + __AutoComplete[id]['element'].value + asugvar;
                }
                else
                {
                	f.submit();
                }
                
                AutoComplete_HideAll();
            }
            else
                result = false;
        }
        return result;
    }
    
    // get the style that will be applied by the browser, including stylesheets
    function sli_getStyle(el,styleProp)
    {
      if (el.currentStyle)
        var y = el.currentStyle[styleProp];
      else if (window.getComputedStyle)
        var y = document.defaultView.getComputedStyle(el,null).getPropertyValue(styleProp);
      return y;
    }

    // register with onLoad(er...
    _sli_init.push( AutoComplete_init );
    
    function sli_addEvent(obj, evType, fn) {
    	if (obj.addEventListener) {
    		obj.addEventListener(evType, fn, false);
    		return true;
    	} else if (obj.attachEvent) {
    		var r = obj.attachEvent("on" + evType, fn);
    		return r;
    	} else {
    		return false;
    	}
    }
    
    function sli_load()
    {
    	sli_addEvent(window, 'load', sli_init);
    }