
(function()
{
    if (window.RAStyles !== true)
    {
        var link = document.createElement("link");
        link.setAttribute("href", "http://www.runningahead.com/themes/default/remote.css");
        link.setAttribute("rel", "stylesheet");
        link.setAttribute("type", "text/css");
        link.setAttribute("media", "all");
        document.getElementsByTagName("head")[0].appendChild(link);
        window.RAStyles = true;
    }
 
    var id = "ra_" + (new Date()).getTime();
    document.write("<span id=\"" + id + "\"></span>");
    var ctrl = document.getElementById(id);
    var div = ctrl.parentNode;
    if (div.tagName != "DIV" || div.className != "RAWidget")
    {
        var tmp = document.createElement("div");
        div.appendChild(tmp, ctrl);
        div.removeChild(ctrl);
        div = tmp;
        div.className = "RAWidget";
    }

    div.innerHTML = "<h3>Latest workouts</h3><table class=\"RARecords\"><tr><td colspan=\"2\">10/11/2011</td></tr><tr><th>Run</th><td><a href=\"http://www.runningahead.com/logs/e2b7b5b988874f8a80982e35a41d224e/workouts/efef6382e47f492e97bfea67395e8287\">3.62 mi</a></td></tr><tr><th>Run</th><td><a href=\"http://www.runningahead.com/logs/e2b7b5b988874f8a80982e35a41d224e/workouts/f877d0213c9246368fd30b711ab56c06\">9.19 mi</a></td></tr><tr><td colspan=\"2\">10/10/2011</td></tr><tr><th>Run</th><td><a href=\"http://www.runningahead.com/logs/e2b7b5b988874f8a80982e35a41d224e/workouts/a76935e05d744de9bc84b8071fef50a3\">4.3 mi</a></td></tr><tr><th>Run</th><td><a href=\"http://www.runningahead.com/logs/e2b7b5b988874f8a80982e35a41d224e/workouts/491be6e47d2140a4b30a2c81f4607958\">1.49 mi</a></td></tr><tr><th>Run</th><td><a href=\"http://www.runningahead.com/logs/e2b7b5b988874f8a80982e35a41d224e/workouts/475c1accafe449da906187c802ddb491\">4.02 mi</a></td></tr></table><div class=\"RAFooter\">  <a href=\"http://www.runningahead.com\">RunningAHEAD</a>  <a href=\"http://www.runningahead.com\">Running Log</a></div>";
}());
