﻿var _version = "005";
function loadProducts(pr, rowCallback, complete) {
    $.get("Products_" + _version + ".xml", {}, function (xml) {
        $("Product", xml).each(function () {
            var id = $(this).find("id").text();
            pr[id] = { category: $(this).find("category").text(),
                name: $(this).find("name").text(),
                description: $(this).find("description").text(),
                weekend: $(this).find("weekend").text(),
                week: $(this).find("week").text(),
                day: $(this).find("day").text(),
                featured: $(this).find("featured").text(),
                quick: $(this).find("quick").text()
            };
            if (rowCallback) rowCallback(id, pr[id]);
        });
        if (complete) complete();
    });
}

var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-12389604-1']);
_gaq.push(['_trackPageview']);

(function () {
    var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
    ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
    (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(ga);
})(); 
