/* Popular phrases - TEDS - 12:46:51, Sun Sep 5, 2010 */
var asPhrases=new Array ('polaroid','60d','binoculars','store locations','competition','waterproof digital camera','nikon d90','canon g11','lenses','polaroid camera','flip','tripod','lumix','nikon d5000','lens','d90','price match','gf1','panasonic gf1','pentax kx','underwater camera','batteries','550d','sony nex-5','lx5','canon 7d','canon 550d','nikon d3000','film scanners','canon 500d','scanner','leica','locations','g11','waterproof','digital photo frame','d5000','polaroid film','nikon d3100','canon lenses','d3100','olympus epl-1','netbook','nex-5','underwater housing','s95','pentax x90','tz10','7d','d3000','pentax k-x','panoramic digital camera','gorillapod','canon powershot','500d','lumix g2','s90','sd card','flip camera','gps camera','digital camera with viewfinder','polaroid 300','panasonic lumix','ixus','fz100','nikon lenses','instant camera','opening hours','canon s90','card reader','manfrotto tripod','film','powershot','nikon','olympus','flash','lx3','video camera','canon','flip ultra hd','canon ixus','monopod','pentax','stores','micro four thirds','waterproof video camera','epl1','olympus lenses','canon eos 1000d','1000d','lowepro','panasonic lumix gf1','photo scanner','waterproof camera','lumix gf1','canon eos','telescope','viewfinder','floating strap','fuji hs10','fz35','media player','olympus pen e-pl1','d300s','canon 50d','canon eos 500d','mini hdmi cable','50mm','waterproof shockproof','canon eos 550d','underwater','tz10 battery','canon 60d','canon 5d','macro lenses','nx10','5d','olympus pen','d700','sx20is','battery charger panasonic','memory kick','canon 1000d','pentax kx dslr','tamron lenses','remote','polaroid 300 instant camera','instant','lumix tz10','canon sx210is','photo competition','panasonic fz35','lumix f3','lumix g10','ft2','remote release nikon','flip mino hd','canon 5d mark ii','sony cybershot','nex5','panasonic','canon s95','nikon flash','tstar case','tamron','sony nex','crumpler','sony nex 5','g2','fuji','panasonic fz100','slr','nex','eos 500d','sigma','panasonic lumix dmc-ft2','nikon coolpix','rode','remote release canon','flip mino hd 2','ml-l3','clubted','lumix lx3','camera armour','sb600','lumix ft2','eos','bloggie','tx5','550d kit','digital camera','panasonic tz10','battery grip','leica x1','fuji finepix','canon remote','strap','inca','asus','fisheye camera','manfrotto','underwater digital camera','mino hd','camera bags','slr cameras','olympus tough','polaroid instant camera','canon powershot sx210 is','nikon d60','asus eee pc','canon 70-200mm','speedlite','samsung st550','lumix g1','vf-2','lumix waterproof','canon macro lenses','bags','5d mark ii','fisheye','samsung','dmcf3 panasonic','canon eos 60d','nikon coolpix p100','16gb sdhc','polaroid 300 film','photo printers','tamron 18-270mm lens','olympus ep-2','hs10','eos 1000d','dslr','sandisk extreme','canon powershot sx20is','eos 60d','nikon remote','flip mino','samsung wb5500','sony','samsung ex1','panasonic lumix g2','olympus ep1','55-250mm is','nikon p100','flip video power adapter','ultra hd flip video','ep2','canon eos 7d','canon eos 5d mark ii','pl150','18-200','kodak zi8','samsung pl150','samsung nx 10','sigma lense','canon sx20is','sony hx5','kx','bg-e2n','camcorder','inca media player','canon lens','x90','cashback','eos 550d','lens adaptor','canon macro','nikon l110','wide angle','case','lp-e5','printer','hdmi cable','nex 5','shockproof waterproof camera','canon eos 550d kit','dvd burner','eos 7d','housing','video mic','video to dvd','dslr bag','ex1','cable','high speed video','lumix fh20','voice','panasonic g2','tamron 17-50mm','sony bloggie','a390','flip ultra','spotting scope','sony nex 3','touch screen cameras','panasonic lumix tz10','panasonic leica d vario-elmar 14-150mm f3.5-5.6 asph mega ois','70-200mm','fuji finepix jz500','inca hd media player','remote controller','cleaning kit','kodak zi8 pocket video camera','sony w350','memory card reader','nikon 18-200mm lens','k-x','bushmaster','canon d10','velbon','sony nex5','panasonic ft2','photoshop','sd60','usb','flip video','canon speedlite 580ex ii','samsung nx10','store opening hours','panasonic lumix lx3','sb400','lp-e6','s6000','nikon dslr','85mm','leica m9','nikon lens','four thirds','canon ixus 300hs','sb 900','canon powershot sx210is','nikon sb 600','kodak playsport','nikon d700','10-20mm','remote control','flipside 300','telephoto lenses','camera straps','fish eye','35mm','fujifilm finepix s1800','s1800','shockproof','olympus sp-600uz','canon 5d mark iii','jvc everio gz-hm330','olympus viewfinder','canon ef','aa battery','panorama','camera case','panasonic lenses','p100','tstar compact','s200exr','pen','14-150mm f4.0-5.6 ultra zoom m.zuiko','50mm f1.8','nikon s8000','wb5500','1005ha','light meter','nex3','microphone jack','nikon coolpix s6000','digital frame','samsung 2 view','canon hfr106 hd','nb4l','sx210is','gh1','pocket hd','fuji f80','webcam','finepix','fh20','inca tripod','panasonic fh20','ixus 130is','sony handycam','handycam','canon bag','canon ixus 210is','sony cybershot w310','sdhc card','ep1','jvc','epl-1','sigma dp2','zi8','memory stick','playsport','tstar tcd1','flash gun','panasonic lx5','nikon slr','flip video camera','photo paper','olympus battery','olympus tough 3000','canon flash','dv','digital slr','pentax k x','canon eos 50d','lumix dmc-fz100','nb-6l','canon ixus 200','g1','rs-60e3','rode mic','sony digital camera','canon powershot camera','sigma 10-20mm','nikon s3000','ipod','olympus sp-800uz','nex 3','coolpix p100','hd media player','nikon binoculars','panasonic tz8','gf1 accessories','fe4030','canon 50mm','sx43 handycam','sony flash','sony a550','canon battery charger','kodak playsport hd waterproof pocket video camera','tamron lens','d3x','film camera','canon 130is','velbon sherpa','bushmaster binoculars','cannon eos 7d','samsung st500','backpack','fh1','panasonic dmc','canon digital','3d','tstar','580ex','canon powershot g11','lumix tz8','sdhc','olympus fe 4000','nikon d90 dslr','warranty','panasonic lx3','pentax optio w80','canon eos 1000d dslr','olympus 9-18mm lens','z70','pentax k7','nikon coolpix l110','e-p1','nikon d300s','sp800uz','nb-5l','ultra sdhc','zi8 remote','wide angle lens','sigma 17-70mm','w80','exr','canon legria hfr106','18-55mm','pentax k-m','extended warranty','sdxc','compact flash','olympus mju 9010','50mm lens canon','manfrotto 190xprob','nova','canon 18-200mm lens','st550','sony hdr-cx110','nikon fisheye','lumix dmc-g2','sony a330','s630','qpix','canon mark ii','remote sony','sb-600','panasonic fh3','polariser','panasonic lumix fz35','fuji finepix hs10','epson','sony hx5v','sling bag','50mm f 1.8','sigma 18-200mm','16gb','pinnacle','tz8','60mm','sony alpha a230','canon powershot s90','sb 400','storage devices','coolpix s8000','mark 2','s4000','gorillapod slr','sigma 18-250mm','s8000','5d kit','np-fv70','lumix dmc-ft2','lumix dmc-gf1','70-300mm','16-35mm','inca universal charger','canon powershot g11 digital camera','xp10','lumix fh22','steady','dmc-g2','cybershot','sony hdrcx110','samsung wb5000','5010','canon ixus 105is','interval record','canon 100mm macro','eos 550d body','w310','canon speedlite 430ex ii','nikon coolpix s570','pentax k','lpe8','professional cameras','sony cybershot w370','waterproof case','ef 50mm','nikon 50mm lens','sony dsc-h55','nikon 35mm','jvc gz-ms120','en-el3e','canon 50mm f 1.8','panasonic lumix fh22','slt','flip mino sd','inspection camera','jvc everio gz-ms120','flip video mino','lens bag','sx120is','leica d lux','canon hfs21','nikon s6000','cannon 500d','tamrac','17-40mm lens','p6000','canon sx120is','s100fs','olympus mju 5010','sx210 is','notebooks','canon 1d','all in one card reader','nikon 18-200mm','dv camera','software','d80','8010','cannon 1000d','hard case','f80exr','panasonic lumix fp1','fs306','5d mark 2','fs37','sb 600','li-42b','75-300mm canon','filter 58mm','85mm f1.4','lens cases','olympus flash','elements','af-s dx nikkor 35mm f 1.8g','canon ef 50mm f1.8','e-pl1','inca accessory kit','bp-819','camera reviews','hd video camera','gps sony','analogue converter','mamiya','manual focus','circular polariser','15-85mm','olympus vf-2','canon ef 50mm f1.4 usm','w380','tough','jvc everio gz-hm200','sony hdr','canon 7 d','nx5','flip power adaptor','smx-c100','of 713','fujifilm s200exr','panasonic sdr','panasonic cameras','fast pack','rechargeable cameras','nd filter','develop film','voice recorders','cannon eos 1000d','second hand','panasonic lumix ft2','d60','qpix fs-170','w370','olympus sp 800uz','pt-ep01','panasonic lumix fh1','finepix hs10','jvc hm350','usb webcam function','kids camera','honl','canon lens 17-40mm','nikon sb-600','sekonic l-358','coolpix','fujifilm s1800','18-105','d90 18-200mm','nikon d100','pen e-pl1','micro sd cards','olympus epl1','nikon d3x','dmc-tz8','inca charger','190xprob','24mm','lp-e6 battery','hv40','secondhand','eee pc 1005ha','dmc-ft2','sigma 50mm','dschx1','carl zeiss','sony dcrsx43','storage','olympus mju tough 3000 digital camera','gz-ms215','rs60e3','canon bg-e3','hd video','wd','k mount','sony fisheye','panasonic sdhc','cannon camera','compact flash sd','in store','professional','bluetooth','viewer','hv30','dv tape','s1000fd','sandisk 8gb','sony bag','50mm f1.4 canon','en-el9a battery','mju 5010','mc-dc2','nikkor 18-200','charger','hdd video','leica v lux 20','300 film','canon selphy','sony sweep','hfr106','sdhc extreme','hx','nikon coolpix s8000','pentax km','lumix lx5','nikon d3000 dslr','h55','gorillapod original','cannon 550d','kodak batteries','hanhel remote','e-p2','velbon 803r','memory stick duo','24-105mm canon','1d marke iii','flipside','270ex','panasonic lumix dmc-fh20','055x prob','manfrotto 128rc','akai digital photo frame','dsch55','lx5 evf','projecter with camera','lowepro rezo 15','7d battery','pentax waterproof','sony memory stick pro duo','slow motion','infrared filter','canon ef 24mm f 1.4 l ii usm lens','tv','300mm lens','optical viewfinder','gp-1 gps','kodak frame','panasonic dvd burner','mb-d80','sherpa','pinnacle studio','gift voucher','17-50mm','sansa','nikon 85mm','slr video','490rc4','leica dslr','xd cards','cannon digital cameras','wx1','sony tx5','nikon speedlight','st500','photo comp','fuji finepix s2000hd','floating','nikon remote ml-l3','fuji xp10','f200exr','sony cybershot tx5','lowepro apex','sony lens','nb-2l','dmc fp1','mic','9010','powershot g11','jz500','velbon sherpa tripod','manfrotto ball head','nikon body','canon bg-e7','18-250mm f3.5-6.3','samsung 30mm','olympus e 30','canon e-p100','ef 16-35mm','sony cybershot tx1','lvf1','gzhm200','1000fps','moisture','grip','dmw-lvf1','spyder2','nb-4l','sb900','lpe6','water resistant','olympus fe4030','ml l3','photoshop elements','300hs','ixus 100','ef 28mm f 2.8','rode video','sigma lens','hfr18','1ds','eos-1d mark iv','canon slr','wb500','selphy','10-22mm','samsung smx-c100','olympus e-30','usb flash drive','cannon s90','pentax lenses','jvc ms120','hd','aa','ep-2','sp600uz','manfrotto modo','powershot sx210 is','dmw-ms1','olympus 9-18','kaiser','camera','sb-900','legria','cd dvd burners','pentax flash','panasonic lumix fh20','video accessories','tough digital cameras','canon eos 500d kit','100mm macro','bp511','130is','18-200mm lens','heads','24-70mm canon','water proof cameras','kodak waterproof','bg-e8','olympus case','canon ixus 100','waterproof camera housing','nikon 12.1','bg-e5','carbon fibre tripod','sigma macro','mini tripod','canon 100-400mm lens','rode video mic','lumix dmc ft2','canon touch','mmf','nikon case','olympus pen 1','vr 18-55 lens','64gb','video head','ef 17','photo maker','dslr d5000','nikon 90','water','canon charger','adobe photoshop elements','lumix dmc-fh1','manfrotto 804rc2','fujifilm finepix s200exr','canon 300hs','pentax optio h90','sony dsc-hx1','d-lux 4','s3000','cannon','nikkor 50mm','epson picturemate','lumix fp1','nikon coolpix s70','digital video camera','flip hd','tstar kit','armour','pentax kx kit','navman','dmc ft2','dmc-fz100','ixus 300hs','canon camera','adapter','nikon d3s','canon hfs20','nikon travelite 10x25','m580','cybershot hx1','nikon 105mm','nikon coolpix p90 digital camera','olympus battery charger','nikon sportstar','canon 110','telstra','lumix fz100','memory stick duo adaptor','panasonic lumix f3','nikon af-s 24-70mm','summicron','sony digital video camera','dmc fh1','xd cameras','konica minolta','lowepro flipside 300','nikon p 90','snapsights','kodak printer dock','hard','copy stand','adventura','speedlite 580ex ii','x1','ms120','kodak playsport hd','105is','d3s','ixus 210is','sweep panorama','tape','ixus 200','olympus tough 8010','sony a390','samsung wb2000','elmo','wireless','olympus ep2','canon legria hfs20','bcg10e','nikon en-el3e','bcg 10e','pentax dslr','tx 7','dcr-sx43','battery nb-5l','nikon gp1','slb-07a','af-s dx nikkor','pentax body','olympus mju tough','vanguard','burner','scope','tripod head','micro','mini hdmi','kodak remote','np-bd1','ght','18-200mm','nikon s4000','canon powershot sx120is','jvc picsio','fuji finepix s200exr','eos 5d','panasonic gh1','olympus e 620','cannon eos 500d','fe-5020','np-fh50','big zoom','panasonic lens','d3','lumix dmc-fp3','500d 18-200','canon eos 5d mark ii kit','nikon speed','fuji s2000hd','4gb memory card','pentax k 7','nb-4l battery','nb-3l','sb','ink','panasonic sd60','nb5l','olympus 8010','pentax k-7','canon ixus 130is','12x','k7','camera with gps','lumix gh1','vhs to dvd','powershot s90','st-e2','panasonic dmc-ft2','sigma lens 17-70mm','adobe photoshop','bp-511','sandisk ultra ii sdhc','canon 1ds','is lenses','fp3','np-bk1','canon nb-5l battery','olympus fe-4000','cannon sx210','x900','35mm afs','nikon battery en-el5','16gb sd','finepix s1000fd','shift lens','leica digital camera','nb2l','pentax macro','canon legria hv40','35 mm film','8gb cf','apex','sony h55','mju tough 8010','leica d-lux','nikon dslr d5000','kodak colour cartridge','sony battery','panasonic dmc-fh1','lumix dmc-fh22','olympus binoculars','pentax w80','canon powershot a495','lumix dmc-fh20','rover','tx-5','panasonic dmc-fh3','inca rapid charger','fe-4030','underwater panasonic','nikon d90 body','canon eos 500d body','np-20','3000','uv','canon fs306','canon hfr18','olympus sp590uz','sony battery charger','pentax h90','optio w80','sony hdrxr200v','dmc-gh1','h.264','hdp-l1','m310w','fuji z70','rs60-e3','nikon 300mm','olympus mju tough 8010 digital camera','terraclime 100','waterproof video','manfrotto 486rc2','panasonic fp1','manfrotto 222','sd sdhc','fl36r','tdk','fuji finepix z70','dmc-fh1','olympus mju 9000 digital camera','zeiss lenses','topload','tcd1','raw','hdrcx350v','slb-11a','samsung 10mp','finepix s1800','fx','kp-108in','olympus 5010','lx-5','dmc-fh3','fl50r','18-135','nikon charger','100-400mm','canon 28mm','panasonic lumix dmc-fz100','sigma 18-125mm','ixus case','compact digital waterproof','canon 430ex','a330','sandisk sansa','coolpix s6000','hx5v','mju tough 3000','lumix fz35','s70','eee pc','300mm lense','vf 2','wifi','canon ef-s 15-85mm','olympus fe 4030','primus','nikon d200','eos 1ds','enel5','compact flash card reader','hmx-r10','nikon cashback','mju 9000','toploader pro 70 aw','akai 9','panasonic g1','tx1','sony video recorder','panasonic lumix f2','pentax e80','universal charger','remote controlled camera','canon eos 1000d digital slr camera','en-el5','cannon g11','olympus 3000','low light','lumix fh1','adobe','everio','lumix 20mm','vrd-p1','accura','s006','18-55mm is','olympus memory card','mirror lens','eee','olympus t100','gel','canon speedlite 270ex','reader','olympus e-pl1','fuji finepix s1500','olympus tough 8000','panasonic f3','online specials','close up lenses','olympus mju tough 8000','dmcfh20','18mp','s570','lp e8','canon hv30','finepix f80','10-24mm','canon powershot d10','olympus ep-1','canon sx210','15-85mm is','hama','canon ef 50mm','200mm','ball head','driver','teds','sony adaptor','fuji provia','velocity','canon ef 15mm f2.8 fish eye','ef 100mm','canon fish eye lense','55-200mm vr','tstar accessory kit','nikkor 35mm','sansa mp3','outback','cd burners','s006e','nikon 70-300mm','vhs','sony sx43','hdr','8000','gz-x900','travel zoom','701rc2','cannon 50mm','canon eos 550d body','remote panasonic','beginner','compass','cx 440','fx lens','membership','nikon 60mm','velbon cx','coolpix l110','d100','v-lux','panasonic lumix fp3','fl-14','a3 printer','128rc','samsung 8','canon lenses 15-85mm','sp 590uz','15 85','sony dvdirect','baas','manfrotto monopod','sony cx110','1d','inca at330','dvd video camera','bounce','datacolor','sony nex3','hd camcorder','canon 15-85mm lens','efs 18-200mm is','sigma 70-300mm lens','panasonic dmc fz100','panasonic lumix tz10 digital camera','18-200mm vr ii zoom','time','ef 75-300mm','release','sd700','manfrotto 785b','panasonic fh1','olympus pen e-p2 kit','pocket video','super zoom','fh3','panasonic lumix g1','lumix lens','dmc-gf1','lumix g series','qpix digital photo frame','sony dslr a380','18-270mm','eh-5a','leather case','1080i','storage viewer','ef','w350','fuji memory card','sony tx','retrospective','15x optical zoom','canon ef 100-400mm','ef 24-70mm f 2.8l','nikkor 35mm f 1.8g','messenger','lens for nikon','remote cord mc-dc2','lumix dmc','epson 210','olympus fe 5020','snap','sony a850','panasonic hdmi cable','nikon 200mm','np-400','nikon 17-55mm','flip ultrahd','canon 35mm lens','extreme','speedlite 270ex','nikon coolpix l110 digital camera','picsio','battery charger pentax','jvc gz-ms215','panasonic lumix g2 blk kit','sx210','sigma 18-50mm','222','dvd camcorder','canon angle finder','590uz','lx-3','my55t','zi8 batterie','olympus lens','panasonic lumix dmc-fp3','sony cybershot w350','battery charger samsung','enel9','kodak video','compact dslr','hfs21','tz-8','62mm polarise','interchangeable lens','f3','video capture','micro slr','14mm','micro four thirds lense','sigma f2.8','manual slr','hm330','hm350','panasonic dmc fh20','lumix 3','npfh50','nikon f1.8','canon is lens','smx-c14','sdr-s26','red','slr case','800uz','sdrs26 sd card camcorder','es73','h90','adventura 120','camera packs','blm-1','a300','digital camera view finder','rc1','fujifilm finepix s2000hd','camera lumix','cf-dc1','hipshot','dsc hx1','retro','olympus pen e-p2','600mm lens','hdrxr200v','17mm','canon dslr 1000d','battery for canon eos 450d','ed','canon 1000d body','pl1','olympus pen ep2','kodak m580','panasonic lumix dmc g2','nikon 400mm','the ultimate slr camera course','pentax slr lenses','panasonic dmc gf1','beauty shot','lumix f2','np-fh70','np-bg1','weather cover','rs80n3','olympus xd card','camera bodies','olympus waterproof','panasonic slr','canon grip','bnfv815','acdsee','pentax 645','nikon s630','canon lenses 17-55mm','sekonic flashmate l-308s light meter','sandisk ultra ii sdhc 16gb','nikon s230','carl','alpha a550','bounce card','sac-47','680b','ef 35mm','fujifilm xp10','fujifilm finepix xp10','dslr 2500','nikon ml l3','af-s','canon ef-s 17-55mm f 2.8 is usm','fuji waterproof','canon mark','napoli 5','f630','sony a230 body','dc310','blm1','finepix z','ef-s 18-55 is lens','nikon mb-d80','coolpix s3000','dc','dmc g10','pentax km pentax da18-55mm kit','sony card','swivel','landscape lens','semi soft-case cf-dc1','m60','mju tough','fuji digital camera','monkey grip tripod','panasonic dmc-f3','4gb ultra','5d ii','ph-157q','lumix dmc-f3','cybershot tx5','sx43','mustek scanner','14mm lens','sony wx-1','monkey tripod','cyber-shot','car charger','ridge 20','fastest shutter speed','canon full frame','sandisk video hd 8gb sdhc card','nikon s620','olympus p1','coolpix s1000pj','cybershot hx5v','af 35mm f 2d','canon ef 15mm f 2.8','bcf-10e','panasonic dmc-gf1','fm500h','samsung video','panasonic fz-35','micro 4 3 lenses','16','olympus 14mp','lumix zoom 12','rd2000','sekonic l358','d5000 remote','olympus tough action pack','small camera','hd pocket video','canon eos 5d mark ii 24-105mm kit','canon 55-200mm','jvc hd','ieee','samsung battery','fujifilm s1600','magic filter','canon ef 85mm','fe 26','jvc bnfv815','canon eos 5d mark ii body','sony w','e 520','samsung slr','panasonic video camera','kodak zx1 remote control','rugged','raw files','date stamp','pinhole camera','5x optical','np-50 battery','efs 18-200 is kit','canon nb-3l','lumix g 20mm','canon 10mp','olympus 17mm f 2.8 lens','p2','canon nb2l','canon nb-2l battery','ef-s 17-55mm f 2.8 is usm','sony battery np-bk1','nikon release','70 200mm canon','panasonic waterproof','compact digital camera with viewfinder','remote control kodak','panasonic lumix waterproof','dslr samsung','pulse','ultra','sony dt','nikon slr lens','14-42','canon ef 28mm','panasonic lumix dmc fh20','cga','mg530','battery nb-6l','full frame camera','olympus pen e','fujifilm f80','fuji exr','slr flashes','nikon 80-400','samsung lens','olympus pen epl1','rm-uc1','samsung hmx','canon 200mm','ball','timelapse','dmc g2','dmcgf1','sony h','14x','nikon af-s dx nikkor 18-55mm f 3.5-5.6g vr','l','lumix 12x','l358','sdr','lp-e4','oled','sony underwater','slr hd video','canon efs 18','720p','ef-s 15-85mm','canon hd hfs21 hd','canon ef 28mm f2.8','canon ef 200mm','canon ef 20mm f 2.8 usm','jvc cu-vs100','canon 550d battery','hdd','cbk4-300','488','canon ef 70','wft-e4','sony grip','p720','cannon d10','fl-36r flashes','camera show','sd14','canon-powershot-sx1is','cga-s005e','cannon binoculars','compact camera waterproof housing','olympus ep-1 compact 12mp dslr twin lens kit','l3','55mm polarising filter','olympus leather','digital notetaker','olympus shock','canon lpe6','stitch assist','el3e','everio gz-hd300','olympus water','canon usm','canon hdmi','flare','nikon camera d3000','samsung smxc10','canon rs-60e3','samsung photo frame','canon digital lenses','sony 10','3','cga-du14','primus aw','samsung vp-dx100i dvd video','sony touch screen','cgr-d08','camera projector','sony twin lens','cameras with viewfinders','samsung remote control','point','canon lens case','cat','cannon ef 70-200 lens','sd video','canon ef 400mm f2.8l usm','canon 18 lens','panasonic lumix dmcfs42 digital camera','canon optical cameras','sony alpha batteries','product return','3 screen','samsung smxc14 sd','shake proof','proof','s007','compu','sony dvd','sony camera lenses','panasonic g','canon secondhand','sprint','1490');
/* $Revision: 6883 $
 *
 */

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';
          if ( theSearchbox.clientWidth < __SLI_customisations[ __SLI_ApplicationName ][ 'DropListMinWidth' ] )
          {
            theDropDown.style.width = __SLI_customisations[ __SLI_ApplicationName ][ 'DropListMinWidth' ];
          }
          else
          {
            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=' + escape(__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' ] + escape(__AutoComplete[id]['element'].value) + asugvar;
          }
          else
          {
            if(f.onsubmit)
            {
              if(f.onsubmit() !== false)
              {
                f.submit();
              }
            }
            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);
    }