var org = {p3k: ({url:"http://news.thomasnet.com/conewsxml/10015874", xml:"<?xml version=\"1.0\" encoding=\"iso-8859-1\"?>\n<!-- generator=\"FeedCreator 1.7.1\" -->\n<rss version=\"2.0\">\n    <channel>\n        <title>RSS Feed for Gates Corporation</title>\n        <description>ThomasNet News is a service of ThomasNet.com</description>\n        <link>http://news.thomasnet.com</link>\n        <lastBuildDate>Sun, 05 Sep 2010 23:20:15 -0400</lastBuildDate>\n        <generator>FeedCreator 1.7.1</generator>\n        <image>\n            <url>http://news.thomasnet.com/images/header/TN_News_footer.gif</url>\n            <title>Powered by ThomasNet News</title>\n            <link>http://news.thomasnet.com</link>\n            <width>129</width>\n            <height>38</height>\n        </image>\n        <item>\n            <title>\nGates Expands Line of Belt Drive and Cooling System Solution Kits for Automotive Aftermarket\n </title>\n            <link>http://news.thomasnet.com/companystory/Gates-Expands-Line-of-Belt-Drive-and-Cooling-System-Solution-Kits-for-Automotive-Aftermarket-833358</link>\n            <description>\nNew Precision Engineered Solution Kits Address Wider Variety of Applications for Domestic and Import Vehicles\n\nDENVER, CO - Gates Corporation today announced the availability of an expanded line of Belt Drive and Cooling System Solution Kits for the automotive aftermarket. From belt jump off to chronic belt noise and cooling system enhancements these precision-engineered Solution Kits were developed to focus on a variety of engine operational issues on domestic and import vehicles. They ...&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/transportation-industry-products' target='_blank''&gt;Transportation Industry Products&lt;/a&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/HVAC' target='_blank''&gt;HVAC&lt;/a&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/mechanical-power-transmission' target='_blank''&gt;Mechanical Power Transmission&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/aftermarket-automotive-parts-96092382-1.html' target='_blank''&gt;Aftermarket Automotive Parts&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/cooling-systems-19651405-1.html' target='_blank''&gt;Cooling Systems&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/belt-drives-96176730-1.html' target='_blank''&gt;Belt Drives&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/vehicle-drives-24424004-1.html' target='_blank''&gt;Vehicle Drives&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Thu, 03 Jun 2010 08:44:20 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nGates Draftguard(TM) Anti-Rotation Device Named Finalist in 2010 'Golden Mousetrap' Competition\n </title>\n            <link>http://news.thomasnet.com/companystory/Gates-Draftguard-TM-Anti-Rotation-Device-Named-Finalist-in-2010-Golden-Mousetrap-Competition-833357</link>\n            <description>\nDenver, CO - Gates Draftguard(TM) anti-rotation device was among the best products of 2010 according to Design News magazine, which named the new product as a finalist in their annual Golden Mousetrap competition.\n\nAccording to Jennifer Roy, Manager Editor, &quot;Design News congratulates the winners and finalists of the 2010 Golden Mousetrap Awards for the great work they've done to develop new and innovative products for design engineers. These products, as always, showcase the highly imaginative ...&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/mechanical-power-transmission' target='_blank''&gt;Mechanical Power Transmission&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/fan-drive-clutches-15430507-1.html' target='_blank''&gt;Fan Drive Clutches&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/automotive-engine-products-95952750-1.html' target='_blank''&gt;Automotive Engine Products&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Thu, 03 Jun 2010 08:44:20 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nGates Corporation Inspires Next Generation of Innovators as Diamond Supplier of the ...</title>\n            <link>http://news.thomasnet.com/companystory/Gates-Corporation-Inspires-Next-Generation-of-Innovators-as-Diamond-Supplier-of-the-FIRST-Robotics-Competition-833356</link>\n            <description>\nFebruary 26, 2010 - Denver, CO - Gates Corporation announced today that it has joined forces with FIRST&amp;#174; (For Inspiration and Recognition of Science and Technology), a not-for-profit organization founded by inventor Dean Kamen, to inspire young people's interest and participation in science and technology, as a Diamond Supplier of the FIRST Robotics Competition (FRC&amp;#174;).\n\nDiamond is the second-highest supplier level for the FIRST Robotics Competition, designating a contribution between $200,000 ...</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Tue, 01 Jun 2010 08:31:40 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nGates Corporation Launches Website for Power Transmission &amp;amp; Motion Control Design ...</title>\n            <link>http://news.thomasnet.com/companystory/Gates-Corporation-Launches-Website-for-Power-Transmission-and-Motion-Control-Design-Solutions-829353</link>\n            <description>\nDesign Engineers Find Free Software Tools, an Interactive Product Catalog and Case Studies Detailing Innovative Uses of Belt Drive Systems\n\nDENVER, CO - Gates Corporation has launched PT Design Source (http://www.gatesprograms.com/ptdesign?sid=prptdesign0809), a website offering application expertise, information on quality products and free software tools to design engineers in the power transmission and motion control fields. Utilizing its resources, engineers can optimize system designs to ...</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Mon, 31 Aug 2009 08:36:03 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nGates Corporation Launches New Website Showing Potential for Energy Savings\n </title>\n            <link>http://news.thomasnet.com/companystory/Gates-Corporation-Launches-New-Website-Showing-Potential-for-Energy-Savings-826210</link>\n            <description>\nVisitors Find Research and Recommendations on Converting to Synchronous Belt Drives to Save Costs\n\nDENVER, CO - Gates Corporation has launched PT Savings Center, an educational website offering resources on energy savings for manufacturing companies, hospitals and other facilities with motor-driven systems.\n\nOn the site, users register for a white paper, entitled &quot;Energy Savings from Synchronous Belt Drives,&quot; download a motor tip sheet from the U.S. Department of Energy and access the Energy ...</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Thu, 23 Apr 2009 08:30:59 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nGates Corporation Earns 2009 Plant Services Best Practices Award\n </title>\n            <link>http://news.thomasnet.com/companystory/Gates-Corporation-Earns-2009-Plant-Services-Best-Practices-Award-825764</link>\n            <description>\nMarch 30, 2009 - Gates Corporation has garnered a prestigious 2009 Best Practices Award from Plant Services magazine for its energy-saving synchronous belt drive systems. The leading manufacturer of industrial products is recognized for its HVAC solutions for Reichhold Inc., a global supplier to the composites and coatings industries.\n\nBy converting various V-belt drives in its Durham, N.C. facility to Gates synchronous belt drives, Reichhold saves more than $34,000 per year in reduced energy ...</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Thu, 02 Apr 2009 08:40:45 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nGates EuroGrip&amp;#174; Flexible Couplings and Decoupler Pulleys Enhance Engine Efficiency \n </title>\n            <link>http://news.thomasnet.com/companystory/Gates-EuroGrip-Flexible-Couplings-and-Decoupler-Pulleys-Enhance-Engine-Efficiency-580663</link>\n            <description>\nInnovative New Couplings Reduce Noise, Vibration and Harshness; Maximize Torque Capability for Improved Vehicle Performance\n\nDenver, CO - Gates Corporation today announced the introduction of a new coupling technology, called EuroGrip&amp;#174;, to the Automotive Aftermarket. Gates originally designed, engineered and produced this new technology for European OEMs as a power transmission product to drive accessories in compact engine compartments.\n\nUsing Gates proven synchronous belt technology, the ...&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/mechanical-power-transmission' target='_blank''&gt;Mechanical Power Transmission&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/flexible-couplings-20192704-1.html' target='_blank''&gt;Flexible Couplings&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Mon, 26 Jul 2010 08:32:30 -0400</pubDate>\n        </item>\n        <item>\n            <title>EPDM Molded Notch V-Belts run smooth and resist cracking.</title>\n            <link>http://news.thomasnet.com/fullstory/EPDM-Molded-Notch-V-Belts-run-smooth-and-resist-cracking-580662</link>\n            <description>\nMolded notch V-belt products are constructed with EPDM (Ethylene Propylene Diene Monomer), whch exhibits resistance to ozone, heat, and weather. Bandless, molded notch construction conserves energy while promoting efficiency, and belts also tolerate misalignment for smoother running performance. Operating from -60 to +230&amp;#176;F, products are resistant to hardening and also meet RMA standards for oil and heat resistance as well as static conductivity.\n&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/mechanical-power-transmission' target='_blank''&gt;Mechanical Power Transmission&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/synthetic-rubber-belting-4752408-1.html' target='_blank''&gt;Synthetic Rubber Belting&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/v-belts-belting-4770400-1.html' target='_blank''&gt;V Belts &amp; Belting&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/belting-4550406-1.html' target='_blank''&gt;Belting&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Mon, 26 Jul 2010 08:31:57 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nGates Alternator Pulley Enhances Engine Efficiency\n </title>\n            <link>http://news.thomasnet.com/companystory/Gates-Alternator-Pulley-Enhances-Engine-Efficiency-577352</link>\n            <description>\nAlternator Decoupler Pulley Reduces Noise and Vibration; Synchronizes Belt Drive System for Improved Vehicle Performance.\n\nDENVER, CO -  Gates Corporation today announced the availability of Gates Alternator Decoupler Pulleys (ADP) for the Automotive Aftermarket that will allow technicians to repair vehicles equipped with these unique pulleys. Replacing the pulley eliminates the need to replace the entire alternator when just the pulley has failed. Substituting a Solid Pulley on an alternator ...&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/mechanical-power-transmission' target='_blank''&gt;Mechanical Power Transmission&lt;/a&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/transportation-industry-products' target='_blank''&gt;Transportation Industry Products&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/pulleys-63833206-1.html' target='_blank''&gt;Pulleys&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/aftermarket-automotive-parts-96092382-1.html' target='_blank''&gt;Aftermarket Automotive Parts&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Fri, 21 May 2010 08:34:37 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nGates Corporation Introduces PartView \n </title>\n            <link>http://news.thomasnet.com/companystory/Gates-Corporation-Introduces-PartView-561897</link>\n            <description>\n Gates Corporation's PartView(TM) Offers Detailed Power Transmission Product Information and 2D/3D CAD Files in a User-Friendly, Online Format\n\nGates Corporation introduces PartView(TM) (http://www.gates.com/partview), a new interactive Industrial Power Transmission catalog. The online resource offers quick access to information about an array of products, including synchronous belts and sprockets, V-belts and sheaves, round belts and preventive maintenance tools.\n\nWith PartView(TM), design ...</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Fri, 12 Jun 2009 08:30:57 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nBend Straight Hose into Any Shape with Unicoil\n </title>\n            <link>http://news.thomasnet.com/companystory/Bend-Straight-Hose-into-Any-Shape-with-Unicoil-551563</link>\n            <description>\nMake molded hose assemblies in minutes with new Unicoil hose benders.\n\nNow you can make custom bends using bulk multi-purpose hose and the new, patented Unicoil hose-bending system. Unicoil is perfect for those one-of-a-kind hose routing problems.\n\no No tools or special equipment required\no Prevents kinks in tight hose bends\no Perfect solution when custom molded hose isn't available or is too costly\n&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/machinery-machining-tools' target='_blank''&gt;Machinery and Machining Tools&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/benders-4910006-1.html' target='_blank''&gt;Benders&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/tube-benders-5031000-1.html' target='_blank''&gt;Tube Benders&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/forming-bending-machinery-46950200-1.html' target='_blank''&gt;Forming &amp; Bending Machinery&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/forming-bending-machinery-46950200-1.html' target='_blank''&gt;Forming &amp; Bending Machinery&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/tube-benders-5031000-1.html' target='_blank''&gt;Tube Benders&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/benders-4910006-1.html' target='_blank''&gt;Benders&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/forming-bending-machinery-46950200-1.html' target='_blank''&gt;Forming &amp; Bending Machinery&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/tube-benders-5031000-1.html' target='_blank''&gt;Tube Benders&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/benders-4910006-1.html' target='_blank''&gt;Benders&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/forming-bending-machinery-46950200-1.html' target='_blank''&gt;Forming &amp; Bending Machinery&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/tube-benders-5031000-1.html' target='_blank''&gt;Tube Benders&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/benders-4910006-1.html' target='_blank''&gt;Benders&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/forming-bending-machinery-46950200-1.html' target='_blank''&gt;Forming &amp; Bending Machinery&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/tube-benders-5031000-1.html' target='_blank''&gt;Tube Benders&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/benders-4910006-1.html' target='_blank''&gt;Benders&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/forming-bending-machinery-46950200-1.html' target='_blank''&gt;Forming &amp; Bending Machinery&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/tube-benders-5031000-1.html' target='_blank''&gt;Tube Benders&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/benders-4910006-1.html' target='_blank''&gt;Benders&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Tue, 11 Nov 2008 08:22:12 -0400</pubDate>\n        </item>\n        <item>\n            <title>Fuel Line Hose meets CARB, EPA, and SAE standards.</title>\n            <link>http://news.thomasnet.com/fullstory/Fuel-Line-Hose-meets-CARB-EPA-and-SAE-standards-551562</link>\n            <description>\nSuited for use in gasoline and diesel engines that power trucks and buses, Barricade(TM) hose with GreenShield(TM) barrier technology keeps permeation of hydrocarbon vapors below limit of 15 g/m&amp;#178;/day to meet California Air Resources Board (CARB) emission requirements, EPA, and SAE J30R14 T2 specifications. It can handle gasoline, diesel fuel, and additives as well as alternative fuels such as Biodiesel and E85 Ethanol. Hose can also be used for crankcase ventilation.\n&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/fluid-gas-flow-equipment' target='_blank''&gt;Fluid and Gas Flow Equipment&lt;/a&gt; Sponsored by:  &lt;a target='_blank' href='http://news.thomasnet.com/redir.html?lnty=rssad&amp;spclid=3243&amp;prid=551562&amp;cat=954&amp;goto=http%3A%2F%2Fwww.snap-titequickdisconnects.com'&gt;SNAP-TITE INC. Quick Disconnect and Valve Div. - Quick Disconnect Coupling Solutions&lt;/a&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/green-clean' target='_blank''&gt;Green &amp; Clean&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/fuel-line-hose-39211008-1.html' target='_blank''&gt;Fuel Line Hose&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Mon, 03 Nov 2008 07:37:00 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nRemove Hose Contamination with MegaClean System\n </title>\n            <link>http://news.thomasnet.com/companystory/Remove-Hose-Contamination-with-MegaClean-System-551560</link>\n            <description>\nRemove dirt from the inside out with Gates MegaClean hose cleanliness system.\n\nStill using shop air to clean the inside of your assemblies? Air alone can't clean the way Gates MegaClean hose and tube cleaning systems can. With the help of pressurized launchers and compatible nozzles, Gates MegaClean foam projectiles sweep through the inside surface of the hose, taking fine particles of loose dirt and other contaminants with them. At 20-30 percent larger than the hose, these projectiles leave ...&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/cleaning-products-equipment' target='_blank''&gt;Cleaning Products and \\\nEquipment&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/hose-pipe-tube-cleaners-14841209-1.html' target='_blank''&gt;Hose, Pipe &amp; Tube Cleaners&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/hose-cleaners-14770788-1.html' target='_blank''&gt;Hose Cleaners&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Thu, 06 Nov 2008 07:22:45 -0400</pubDate>\n        </item>\n        <item>\n            <title>Digital Crimper handles up to 6 in. hose.</title>\n            <link>http://news.thomasnet.com/fullstory/Digital-Crimper-handles-up-to-6-in-hose-551559</link>\n            <description>\nFeaturing 2-stage crimping process, foot pedal crimping control, and touchpad, GC96(TM) can crimp up to 6 in. industrial hose or 2 in. hydraulic hose assemblies. Head allows hose assemblies to be made with various terminations using crimpable ferrules and sleeves. For universal applicability, tool automatically converts any local electrical input (208-264 V, 3-phase) into compatible power source. Crimper also features self-diagnostic indicator lights and modular, plug-and-play design.\n&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/portable-tools' target='_blank''&gt;Portable Tools&lt;/a&gt; Sponsored by:  &lt;a target='_blank' href='http://news.thomasnet.com/redir.html?lnty=rssad&amp;spclid=3104&amp;prid=551559&amp;cat=2196&amp;goto=http%3A%2F%2Fwww.channellock.com'&gt;Channellock, Inc. - Work Hard. Sweat Blue. Made in USA since 1886.&lt;/a&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/machinery-machining-tools' target='_blank''&gt;Machinery and Machining Tools&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/electric-crimper-tools-21010905-1.html' target='_blank''&gt;Electric Crimper Tools&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/crimping-machinery-46351201-1.html' target='_blank''&gt;Crimping Machinery&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Mon, 03 Nov 2008 07:37:00 -0400</pubDate>\n        </item>\n        <item>\n            <title>Hose handles liquid and gaseous butane and/or propane.</title>\n            <link>http://news.thomasnet.com/fullstory/Hose-handles-liquid-and-gaseous-butane-and-or-propane-551526</link>\n            <description>\nDesigned to convey liquid or gaseous butane, propane, or some combination thereof, LP350X hose is comprised of Type C (Nitrile) tube with synthetic textile cord reinforcement and Type A (Neoprene) cover. It handles continuous service operating temperatures from -40 to +180&amp;#176;F and is compatible with all GLX(TM) couplings/terminations. In addition to use with various outdoor equipment, hose is suited for construction applications and natural gas transfer.\n&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/fluid-gas-flow-equipment' target='_blank''&gt;Fluid and Gas Flow Equipment&lt;/a&gt; Sponsored by:  &lt;a target='_blank' href='http://news.thomasnet.com/redir.html?lnty=rssad&amp;spclid=3243&amp;prid=551526&amp;cat=954&amp;goto=http%3A%2F%2Fwww.snap-titequickdisconnects.com'&gt;SNAP-TITE INC. Quick Disconnect and Valve Div. - Quick Disconnect Coupling Solutions&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/reinforced-hose-39310305-1.html' target='_blank''&gt;Reinforced Hose&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/low-pressure-hose-39251905-1.html' target='_blank''&gt;Low Pressure Hose&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/high-temperature-hose-39230909-1.html' target='_blank''&gt;High Temperature Hose&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Mon, 03 Nov 2008 07:37:00 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nNew Petroleum Transfer Hose Handles Alternative Fuels\n </title>\n            <link>http://news.thomasnet.com/companystory/New-Petroleum-Transfer-Hose-Handles-Alternative-Fuels-551525</link>\n            <description>\n11-01-2008\n\nNew Longhorm&amp;#174; AF petroleum transfer hose from Gates can efficiently and safely handle bio-diesel, ethanol and other petroleum-based products.\n\nThe hose is specifically designed and engineered for constant contact use in the transfer of alternative fuels such as bio-diesel, bio-diesel blends, ethanol and ethanol blends. It can also be used for transfer of commercial gasolines, diesel fuels, oils and other petroleum products. It is ideal for tank truck, terminal loading and in-plant ...&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/fluid-gas-flow-equipment' target='_blank''&gt;Fluid and Gas Flow Equipment&lt;/a&gt; Sponsored by:  &lt;a target='_blank' href='http://news.thomasnet.com/redir.html?lnty=rssad&amp;spclid=3243&amp;prid=551525&amp;cat=954&amp;goto=http%3A%2F%2Fwww.snap-titequickdisconnects.com'&gt;SNAP-TITE INC. Quick Disconnect and Valve Div. - Quick Disconnect Coupling Solutions&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/loading-unloading-hose-39251806-1.html' target='_blank''&gt;Loading &amp; Unloading Hose&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/petroleum-hose-39290309-1.html' target='_blank''&gt;Petroleum Hose&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/loading-unloading-hose-39251806-1.html' target='_blank''&gt;Loading &amp; Unloading Hose&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/petroleum-hose-39290309-1.html' target='_blank''&gt;Petroleum Hose&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Mon, 03 Nov 2008 07:37:33 -0400</pubDate>\n        </item>\n        <item>\n            <title>Crimpable Thermoplastic Hoses offer leak-proof design.</title>\n            <link>http://news.thomasnet.com/fullstory/Crimpable-Thermoplastic-Hoses-offer-leak-proof-design-551524</link>\n            <description>\nAvailable in conductive and nonconductive constructions, TH7 and TH8 hoses handle petroleum, water-based fluids and synthetic hydraulic fluids. Applications include general hydraulic systems, hydraulic tools, mobile equipment, and high-pressure pneumatic systems up to 500 psi. They are compatible with Gates MegaCrimp&amp;#174; couplings featuring C-insert for leak-proof seal.\n&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/fluid-gas-flow-equipment' target='_blank''&gt;Fluid and Gas Flow Equipment&lt;/a&gt; Sponsored by:  &lt;a target='_blank' href='http://news.thomasnet.com/redir.html?lnty=rssad&amp;spclid=3243&amp;prid=551524&amp;cat=954&amp;goto=http%3A%2F%2Fwww.snap-titequickdisconnects.com'&gt;SNAP-TITE INC. Quick Disconnect and Valve Div. - Quick Disconnect Coupling Solutions&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/thermoplastic-hose-39390679-1.html' target='_blank''&gt;Thermoplastic Hose&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/high-pressure-hose-39230800-1.html' target='_blank''&gt;High Pressure Hose&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/industrial-hose-95926655-1.html' target='_blank''&gt;Industrial Hose&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/flexible-plastic-hose-96096672-1.html' target='_blank''&gt;Flexible Plastic Hose&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Mon, 03 Nov 2008 07:37:00 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nXtraTuff Hose Stands Up to Abrasive Environments\n </title>\n            <link>http://news.thomasnet.com/companystory/XtraTuff-Hose-Stands-Up-to-Abrasive-Environments-551521</link>\n            <description>\nGates XtraTuff(TM) hose will stand up to your toughest abrasive applications.\n\nMade of special hybrid compounds, Gates XtraTuff cover offers 25 times the abrasion resistance of M3K, M4K and M5K standard cover hydraulic hose. It increases service life, lowers maintenance and eliminates the need for costly hose protectors like spring guards and nylon sleeves. XtraTuff hose is versatile, flexible and easy to manage. With a pressure rating of up to 5,000 psi, it will outperform anything the ...&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/fluid-gas-flow-equipment' target='_blank''&gt;Fluid and Gas Flow Equipment&lt;/a&gt; Sponsored by:  &lt;a target='_blank' href='http://news.thomasnet.com/redir.html?lnty=rssad&amp;spclid=3243&amp;prid=551521&amp;cat=954&amp;goto=http%3A%2F%2Fwww.snap-titequickdisconnects.com'&gt;SNAP-TITE INC. Quick Disconnect and Valve Div. - Quick Disconnect Coupling Solutions&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/hydraulic-hose-39231204-1.html' target='_blank''&gt;Hydraulic Hose&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Thu, 06 Nov 2008 07:22:45 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nMegaTuff Hose Cover Eliminates Need for Spring Guards or Nylon Sleeving\n </title>\n            <link>http://news.thomasnet.com/companystory/MegaTuff-Hose-Cover-Eliminates-Need-for-Spring-Guards-or-Nylon-Sleeving-551520</link>\n            <description>\nNothing is harder on hydraulic hose than the constant abrasion it takes day after day. Rubbed against metal or other hose, most hydraulic hoses - even ones with spring guards or nylon sleeving - can't take the punishment. And you shouldn't have to take the high cost of frequent hose replacements.\n\nMegaTuff hydraulic hoses take the load off your hose and your wallet. In I.D.s from 3/8-inch to 2-inches in spiral-wire construction and 1/4-inch to 1-inch in wire-braid construction, MegaTuff hoses ...&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/fluid-gas-flow-equipment' target='_blank''&gt;Fluid and Gas Flow Equipment&lt;/a&gt; Sponsored by:  &lt;a target='_blank' href='http://news.thomasnet.com/redir.html?lnty=rssad&amp;spclid=3243&amp;prid=551520&amp;cat=954&amp;goto=http%3A%2F%2Fwww.snap-titequickdisconnects.com'&gt;SNAP-TITE INC. Quick Disconnect and Valve Div. - Quick Disconnect Coupling Solutions&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/hydraulic-hose-39231204-1.html' target='_blank''&gt;Hydraulic Hose&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/wire-reinforced-hose-39420757-1.html' target='_blank''&gt;Wire Reinforced Hose&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Thu, 06 Nov 2008 07:22:45 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nRevolutionary Sleeving Protects Hoses Against Extreme Temperatures\n </title>\n            <link>http://news.thomasnet.com/companystory/Revolutionary-Sleeving-Protects-Hoses-Against-Extreme-Temperatures-551519</link>\n            <description>\nHeatGuard(TM) sleeving can literally take the heat.\n\nIn the world of hydraulics, things can literally get red hot. Use Gates HeatGuard sheathing to help protect critical hoses and couplings from sparks, molten splash, heat and fire.\n\nHeatGuard sleeving is constructed of tightly woven fiberglass on the inside...and a specially compounded, heat-resistant silicone rubber cover on the outside. HeatGuard sheathing provides superior protection in work environments that can reach ultra-high ...&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/electrical-equipment-systems' target='_blank''&gt;Electrical Equipment and Systems&lt;/a&gt; Sponsored by:  &lt;a target='_blank' href='http://news.thomasnet.com/redir.html?lnty=rssad&amp;spclid=4114&amp;prid=551519&amp;cat=612&amp;goto=http%3A%2F%2Fwww.globtek.com'&gt;Globtek Inc. - Your Power Partner...For Over 20 Years!&lt;/a&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/mechanical-components-assemblies' target='_blank''&gt;Mechanical Components and Assemblies&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/high-temperature-sleeving-75810945-1.html' target='_blank''&gt;High Temperature Sleeving&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/protective-sleeves-75790402-1.html' target='_blank''&gt;Protective Sleeves&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/silicone-coated-sleeving-75811380-1.html' target='_blank''&gt;Silicone Coated Sleeving&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/fiberglass-sleeving-75810804-1.html' target='_blank''&gt;Fiberglass Sleeving&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Thu, 06 Nov 2008 07:22:45 -0400</pubDate>\n        </item>\n        <item>\n            <title>Hydraulic Fittings prevent premature coupling failure.</title>\n            <link>http://news.thomasnet.com/fullstory/Hydraulic-Fittings-prevent-premature-coupling-failure-551517</link>\n            <description>\nAvailable on MegaCrimp&amp;#174; couplings for wire-braid hose and GlobalSpiral&amp;#174; couplings for spiral-wire hose, Full-Torque Nut(TM) couplings have large holding shoulders that evenly distribute stress forces at nut for resistance to over-torquing and cracking. Consistent sealing force promotes leak protection, and nut size is optimized for wrench access. Available in metric sizes only (female fittings), products feature TuffCoat(TM) plating for resistance to rust and corrosion.\n&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/fluid-gas-flow-equipment' target='_blank''&gt;Fluid and Gas Flow Equipment&lt;/a&gt; Sponsored by:  &lt;a target='_blank' href='http://news.thomasnet.com/redir.html?lnty=rssad&amp;spclid=3243&amp;prid=551517&amp;cat=954&amp;goto=http%3A%2F%2Fwww.snap-titequickdisconnects.com'&gt;SNAP-TITE INC. Quick Disconnect and Valve Div. - Quick Disconnect Coupling Solutions&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/hydraulic-couplings-20250205-1.html' target='_blank''&gt;Hydraulic Couplings&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/hydraulic-fittings-29810603-1.html' target='_blank''&gt;Hydraulic Fittings&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Tue, 11 Nov 2008 08:33:18 -0400</pubDate>\n        </item>\n        <item>\n            <title>\nThere's a Better Way to Protect Against Hydraulic Hose Failure\n </title>\n            <link>http://news.thomasnet.com/companystory/There-s-a-Better-Way-to-Protect-Against-Hydraulic-Hose-Failure-551516</link>\n            <description>\nLine-of-Sight Sleeving is the Safest Alternative for Protecting Operators and Personnel\n\nProtective covers for hydraulic hose assemblies are taking on a whole new meaning.\n\nThey are still being used to protect hoses on mobile construction and mining equipment. However, with the need for higher-pressure systems and more compact machine designs, design engineers are increasingly looking for ways to safely protect machine operators and personnel from catastrophic hydraulic hose failure.\n\nFirst ...&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/electrical-equipment-systems' target='_blank''&gt;Electrical Equipment and Systems&lt;/a&gt; Sponsored by:  &lt;a target='_blank' href='http://news.thomasnet.com/redir.html?lnty=rssad&amp;spclid=4114&amp;prid=551516&amp;cat=612&amp;goto=http%3A%2F%2Fwww.globtek.com'&gt;Globtek Inc. - Your Power Partner...For Over 20 Years!&lt;/a&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/plant-furnishings-accessories' target='_blank''&gt;Plant Furnishings and Accessories&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/protective-sleeving-75811166-1.html' target='_blank''&gt;Protective Sleeving&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/protective-covers-20610606-1.html' target='_blank''&gt;Protective Covers&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/hydraulic-hose-sleeves-97002514-1.html' target='_blank''&gt;Hydraulic Hose Sleeves&lt;/a&gt;  |  &lt;a href='http://www.thomasnet.com/products/abrasion-resistant-sleeves-97002515-1.html' target='_blank''&gt;Abrasion Resistant Sleeves&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Thu, 06 Nov 2008 07:22:45 -0400</pubDate>\n        </item>\n        <item>\n            <title>Non-Marking Drive Belt minimizes noise and dust.</title>\n            <link>http://news.thomasnet.com/fullstory/Non-Marking-Drive-Belt-minimizes-noise-and-dust-539871</link>\n            <description>\nFeaturing nylon tooth surface that minimizes dust accumulation, PowerGrip&amp;#174; TruMotion&amp;#174; Belt provides durable wear surface for medical instrumentation, office automation, electronics, and banking. Three tooth profile options, including timing, HTD, and curvilinear, all offer exact meshing characteristics for elimination of tooth slip. Hardened fiberglass tensile cords resist elongation, while polymer compound body handles temperatures from -40 to +220&amp;#176;F.\n&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/mechanical-power-transmission' target='_blank''&gt;Mechanical Power Transmission&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/drive-belts-4802906-1.html' target='_blank''&gt;Drive Belts&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Tue, 12 Feb 2008 07:34:19 -0400</pubDate>\n        </item>\n        <item>\n            <title>Transmission Belt reduces downtime for RPP drives.</title>\n            <link>http://news.thomasnet.com/fullstory/Transmission-Belt-reduces-downtime-for-RPP-drives-458230</link>\n            <description>Eliminator&amp;#226;&amp;quot;&amp;#162; belt, engineered to replace RPP&amp;#174; tooth profile belts of same width and comparable length, run on existing RPP sprockets and idlers with same tension as original belt. Polyurethane synchronous belts with green tooth color are available in 8 mm pitch size with 12, 22, 35, and 60 mm widths; 26 belt lengths; and 104 part numbers, or 14 mm pitch size with 20, 42, 65, 90, and 120 mm widths; 16 belt lengths; and 80 part numbers.&lt;br&gt;&lt;br&gt;&lt;b&gt;This story is related to the following:&lt;/b&gt;&lt;br&gt;&lt;a href='http://news.thomasnet.com/news/mechanical-power-transmission' target='_blank''&gt;Mechanical Power Transmission&lt;/a&gt;&lt;br&gt;&lt;br&gt;Search for suppliers of: &lt;a href='http://www.thomasnet.com/products/transmission-belting-4761003-1.html' target='_blank''&gt;Transmission Belting&lt;/a&gt;&lt;br&gt;</description>\n            <author>info@productnews.com (ThomasNet News)</author>\n            <pubDate>Fri, 10 Dec 2004 07:52:29 -0400</pubDate>\n        </item>\n    </channel>\n</rss>\n", message:undefined, modified:(new Date(1283743215450)), baseUri:"http://p3k.org/rss/", query:"textColor=#000000&width=500&align=&fontFace=&url=http://news.thomasnet.com/conewsxml/10015874&frameColor=black&compact=&showXmlButton=&setup=true&boxFillColor=white&_=1266198637079&titleBarColor=orange&maxItems=7&titleBarTextColor=black&", param:{textColor:"#000000", align:"", width:"500", fontFace:"", url:"http://news.thomasnet.com/conewsxml/10015874", compact:"", frameColor:"black", showXmlButton:"", setup:"true", boxFillColor:"white", _:"1266198637079", titleBarColor:"orange", maxItems:"7", titleBarTextColor:"black"}, box:"<table class=\"rssBox\" width=\"${width}\" bgcolor=\"${frameColor}\" \n      style=\"table-layout: fixed; overflow: hidden; font-family: ${fontFace};\" \n      align=\"${align}\" cellspacing=\"1\" cellpadding=\"7\" border=\"0\">\n<tr bgcolor=\"${titleBarColor}\">\n<td>\n   ${xmlButton}\n   <strong>${title}</strong>\n   <div>\n      <small style=\"color: ${titleBarTextColor};\">${date}</small>\n   </div>\n</td>\n</tr>\n<tr bgcolor=\"${boxFillColor}\">\n<td class=\"rssBoxContent\" style=\"color: ${textColor};\">\n   ${image}\n   ${items}\n   ${input}\n   <div class=\"rssBoxPromo\" style=\"margin-top: 0px; text-align: left; \n         font: 9px verdana, sans-serif\">\n      RSS box by <a href=\"http://p3k.org/rss\">p3k.org</a>.\n   </div>\n</td>\n</tr>\n</table>\n\n", image:"<a href=\"${link}\"><img src=\"${source}\" width=\"${width}\" height=\"${height}\" \nalt=\"${title}\" title=\"${title}\" align=\"${align}\" valign=\"${valign}\" \nhspace=\"${hspace}\" vspace=\"${vspace}\" border=\"0\" /></a>\n\n", input:"<form method=\"get\" action=\"${link}\">\n${description}\n<input type=\"text\" name=\"${name}\" size=\"15\" /> <input type=\"submit\" \nvalue=\"${title}\" />\n</form>\n\n", item:"<div class=\"rssBoxItemContent\">\n${title}\n${break}\n${description}\n${buttons}\n</div><br />\n\n", date:"${year}-${month}-${day}, ${hours}:${minutes}h\n\n", link:"<a class=\"${class}\" href=\"${link}\" style=\"${style}\">${text}</a>\n", error:"<?xml version=\"1.0\"?>\n<rss version=\"error\">\n   <channel>\n      <title>RSS Box Error</title>\n      <link>${link}</link>\n      <description>This output was automatically generated to report an error \n      that occurred during a request to the JavaScript RSS Box Viewer.</description>\n      <item>\n         <title>Oops, something went wrong...</title>\n         <description>An error occurred while processing the request to the \n         JavaScript RSS Box Viewer.</description>\n      </item>\n      <item>\n         <title>An error message was returned by the server.</title>\n         <description>${message}</description>\n      </item>\n      <item>\n         <description>Most likely, this might have happened because of a \n         non-existent or invalid RSS feed URL. Please check and possibly correct \n         your input, then try again.</description>\n      </item>\n   </channel>\n</rss>\n\n"})};
function debug(str) {
   return document.write('<p><span style="background-color: yellow;">', 
         str, '</span><p>');
}

org.p3k.RssBox = function() {
   var ref;
   var ISOPATTERN = /([0-9]{4})-([0-9]{2})-([0-9]{2})T([0-9:]+).*$/;
   
   var data = org.p3k;
   data.defaults = {
      url: "http://blog.p3k.org/rss",
      maxItems: 7,
      width: 200,
      align: "",
      frameColor: "black",
      titleBarColor: "lightblue",
      titleBarTextColor: "black",
      boxFillColor: "white",
      textColor: "black",
      showXmlButton: "",
      compact: ""
   };
   
   var baseUri = data.baseUri;
    
   var getColor = function(str) {
      if (str.length === 6 && parseInt(str, 16) && str.indexOf("#") !== 0) {
         str = "#" + str;
      }
      return str.toLowerCase();
   }

   var value;
   for (var i in data.defaults) {
      value = data.param[i];
      if (!value || value.length === 0) {
         data.param[i] = data.defaults[i];
      } else if (i.indexOf("Color") > 0) {
         data.param[i] = getColor(value);
      }
   }

   // FIXME: Ugly work-around for many boxes using too small width 
   // values because the former version did not show the exact output.
   if (data.param.javascript && data.param.width < 200) {
      data.param.width = 200;
   }
   // Remove obsolete parameters from param and query
   delete data.param.javascript;
   data.query = data.query.replace("javascript=true", "");   

   var NAMESPACES = {
      dc: "http://purl.org/dc/elements/1.1/",
      rdf: "http://www.w3.org/1999/02/22-rdf-syntax-ns#"
   };

   var getUrl = function(url) {
      url = baseUri + "proxy.r?" + encodeURIComponent(url);
   
      var HttpRequest = function() {
         return (typeof XMLHttpRequest !== "undefined") ?
            new XMLHttpRequest() : new ActiveXObject("Msxml2.XMLHTTP");
      }
   
      var request = new HttpRequest();
      request.open("GET", url, false);
      request.send(null);   
      if (!request.getResponseHeader("Date")) {
         var cached = request;
         var ifModifiedSince = cached.getResponseHeader("Last-Modified") || 
               new Date(0); // January 1, 1970
         request = new HttpRequest();
         request.open("GET", url, false);
         request.setRequestHeader("If-Modified-Since", ifModifiedSince);
         request.send("");
         if (request.status === 304) {
            request = cached; 
         }
      }
      return request;
   }
   
   var getDocument = function(source) {
      if (source) {
         if (document.implementation.createDocument) {
            var parser = new DOMParser();
            var doc = parser.parseFromString(source, "text/xml");
            return doc;
         } else if (window.ActiveXObject) {
            var doc = new ActiveXObject("Microsoft.XMLDOM");
            doc.async = "false";
            doc.loadXML(source);
            return doc;
         }
      }
      return null;
   }
   
   var getError = function() {
      var msg = null, root;
      if (!xml || data.message) {
         msg = data.message || "Unknown error.";
      } else if (xml.parseError && xml.parseError.errorCode) {
         msg = xml.parseError.reason; // IExplore
      } else if (root = xml.documentElement) {
         var errorNode;
         if (root.nodeName === "parsererror") {
            msg = xml.documentElement.textContent; // Mozilla
         } else if ((errorNode = root.childNodes[0]) && 
               errorNode.nodeName === "parsererror") {
            msg = errorNode.textContent; // Safari
         } else if (!/rss|rdf|scriptingNews/i.test(xml.documentElement.nodeName)) {
            msg = "Incompatible data format. Are you sure this is an RSS feed?";
         }
      }
      return msg;
   }
   
   var getNode = function(parent, name, namespace) {
      if (namespace) {
         if (typeof parent.getElementsByTagNameNS === "undefined") {
            var elements = parent.getElementsByTagName(namespace + ":" + name);
         } else {
            var elements = parent.getElementsByTagNameNS(NAMESPACES[namespace], name);
         }
      } else {
         var elements = parent.getElementsByTagName(name);
      }
      if (elements && elements[0]) {
         return elements[0];
      }
      return null;
   }
   
   var getText = function(node) {
      if (node && node.childNodes && node.childNodes.length > 0) {
         return node.childNodes[0].nodeValue || "";
      }
      return "";
   }
   
   var trim = function(str) {
      if (str) {
         return str.replace(/^\s*(\S*)\s*$/, "$1");
      }
      return "";
   }
   
   var padZero = function(n) {
      if (n < 10) {
         return "0" + n
      }
      return n;
   }

   var encodeXml = function(str) {
      if (!str) {
         return "";
      }
      return str.replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/&/g, "&amp;");
   }
      
   var render = function(template, param) {
      if (!template || !param) {
         return template;
      }
      template = template.replace(/\$\{([^}]+)\}/g, function() {
         var key = arguments[1];
         return param[key] || "";
      });
      return template;
   }
   
   var renderDate = function(date) {
      if (date.constructor !== Date) {
         var str = String(date);
         var millis = Date.parse(str.replace(ISOPATTERN, "$1/$2/$3 $4"));
         if (millis) {
            date = new Date(millis);
         } else {
            date = new Date;
         }
      }

      return render(data.date, {
         year: date.getFullYear(),
         month: padZero(date.getMonth() + 1),
         day: padZero(date.getDate()),
         hours: padZero(date.getHours()),
         minutes: padZero(date.getMinutes()),
         seconds: padZero(date.getSeconds()),
         timeZone: "" // date.getTimezoneOffset()
      });
   }
   
   var renderButtons = function(enclosure, source) {
      var result = "";
      if (enclosure && enclosure.link) {
         result += render(data.image, {
            source: baseUri + "enclosure.gif",
            title: enclosure.type,
            link: encodeURI(enclosure.link),
            width: 13,
            height: 16
         });
      }
      if (source && source.link) {
         result += render(data.image, {
            source: baseUri + "source.gif",
            title: source.title,
            link: encodeURI(source.link),
            width: 15,
            height: 15
         });
      }
      return result;         
   }
   
   var param = data.param;
   var rss = data.rss = {items: []};
   var xml = getDocument(data.xml);

   rss.error = getError();
   if (rss.error !== null) {
      xml = getDocument(render(data.error, {
         link: baseUri + "?" + encodeXml(data.query),
         message: encodeXml(rss.error)
      }));
      param.compact = 0;
      param.showXmlButton = 1;
   }

   var root = xml.documentElement;
   var type = root.nodeName;

   if (type === "scriptingNews") {
      var channel = getNode(xml, "header");
      rss.format = "Scripting News";
      rss.version = getText(getNode(channel, "scriptingNewsVersion"));
      rss.title = getText(getNode(channel, "channelTitle"));
      rss.description = getText(getNode(channel, "channelDescription"));
      rss.link = getText(getNode(channel, "channelLink"));
      if (ref = getText(getNode(channel, "imageUrl"))) {
         ref = rss.image = {source: ref};
         ref.title = getText(getNode(channel, "imageTitle"));
         ref.link = getText(getNode(channel, "imageLink"));
         ref.width = getText(getNode(channel, "imageWidth"));
         ref.height = getText(getNode(channel, "imageHeight"));
         ref.description = getText(getNode(channel, "imageCaption"));
      }
   } else {
      var channel = getNode(xml, "channel");
      rss.format = "RSS";
      rss.version = (type === "rdf:RDF") ? "1.0" : 
            root.getAttribute("version");
      rss.title = getText(getNode(channel, "title"));
      rss.description = getText(getNode(channel, "description"));
      rss.link = getText(getNode(channel, "link"));
      var image = getNode(xml, "image");
      if (image) {
         ref = rss.image = {};
         ref.source = getText(getNode(image, "url"));
         ref.title = getText(getNode(image, "title"));
         ref.link = getText(getNode(image, "link"));
         ref.width = getText(getNode(image, "width"));
         ref.height = getText(getNode(image, "height"));
         ref.description = getText(getNode(image, "description"));
      }
   }
   
   if (type === "rdf:RDF") {
      rss.date = renderDate(getText(getNode(channel, "date", "dc")) || data.modified);
      rss.rights = getText(getNode(channel, "creator", "dc"));
      var input = getNode(root, "textinput");
      if (input && !getNode(input, "link")) {
         input = root.getElementsByTagName("textinput")[1];
      }
      if (input) {
         ref = rss.input = {};
         ref.link = getText(getNode(input, "link"));
         ref.description = getText(getNode(input, "description"));
         ref.name = getText(getNode(input, "name"));
         ref.title = getText(getNode(input, "title"));
      }
   } else {
      rss.date = renderDate(getText(getNode(channel, "lastBuildDate") || getText(getNode(channel, "pubDate"))) || data.modified);
      rss.rights = getText(getNode(channel, "copyright"));
   }
   
   var item, text, node;
   var items = xml.getElementsByTagName("item");

   for (var i=0; i<Math.min(items.length, param.maxItems); i+=1) {
      item = items[i];

      if (type === "scriptingNews") {
         ref = {title: ""};
         ref.description = getText(getNode(item, "text")).replace(/\n/g, " ");
         ref.link = getText(getNode(item, "link"));
         if (text = trim(getText(getNode(item, "linetext")).replace(/\n/g, " "))) {
            ref.description = ref.description.replace(new RegExp(text), 
                  '<a href="' + getText(getNode(item, "url")) + '">' + text + '</a>');
         }
      } else {
         ref = {
            title: getText(getNode(item, "title")),
            description: getText(getNode(item, "description")),
            link: getText(getNode(item, "link") || getNode(item, "guid"))
         };
     }

     if (node = getNode(item, "source")) {
        ref.source = {
           link: node.getAttribute("url"),
           title: getText(node)
        }
     }
     
     if (node = getNode(item, "enclosure")) {
        ref.enclosure = {
           link: node.getAttribute("url"),
           length: node.getAttribute("length"),
           type: node.getAttribute("type")
        }
     }
     
     if (node = getNode(item, "category")) {
        ref.category = {
           domain: node.getAttribute("domain") || "",
           content: getText(node)
        }
     }
     
     rss.items.push(ref);
   }
   
   var item, items = "";
   for (var i=0; i<rss.items.length; i+=1) {
      item = rss.items[i];
      items += render(data.item, {
         title: new function() {
            var title = (!param.compact ? "<strong>" : "");
            if (item.link) {
               title += render(data.link, {
                  link: encodeURI(item.link),
                  text: item.title,
                  'class': "rssBoxItemTitle"
               });
            } else {
               title += item.title;
            }
            !param.compact && (title += "</strong>");
            return new String(title); // FIXME: Funny, title alone will be rendered as [object]
         }(),
         'break': item.title && item.description ? "<br />" : "",
         description: (!param.compact || !item.title) && item.description,
         buttons: renderButtons(item.enclosure, item.source)
      });
   }
   
   var box = render(data.box, {
      title: rss.link ? render(data.link, {
         link: encodeURI(rss.link),
         text: rss.title,
         'class': "rssBoxTitle",
         style: "color: " + param.titleBarTextColor
      }) : rss.title,
      description: rss.description,
      items: items,

      xmlButton: param.showXmlButton && render(data.image, {
         link: param.url,
         source: baseUri + "rss.png",
         title: rss.format + " " + rss.version,
         width: 16,
         height: 16,
         align: "right",
         hspace: 3
      }),
      
      image: !param.compact && rss.image && render(data.image, {
         link: encodeURI(rss.image.link),
         source: rss.image.source,
         width: rss.image.width,
         height: rss.image.height,
         title: rss.image.title,
         align: "right",
         valign: "baseline",
         hspace: 5,
         vspace: 5
      }),
      
      input: !param.compact && rss.input && render(data.input, {
         link: encodeURI(rss.input.link),
         description: rss.input.description,
         name: rss.input.name,
         title: rss.input.title
      }),
      
      date: rss.date,
      width: param.width,
      frameColor: param.frameColor,
      fontFace: param.fontFace,
      align: param.align,
      titleBarColor: param.titleBarColor,
      titleBarTextColor: param.titleBarTextColor,
      boxFillColor: param.boxFillColor,
      textColor: param.textColor
   });

   if (!window.rssBoxSetup) {
      document.write(box);
   }
   
   return box;
};

org.p3k.RssBox();

