﻿
var size = 4;
var tinyDates = new Array(size);
tinyDates[0]="1m";
tinyDates[1]="1q";
tinyDates[2]="1y";
tinyDates[3]="5y";
var tinyGraph=new Array(size);
var tinyButton_hover=new Array(size);
var tinyButtons=new Array(size);
if (document.images){
 for(var i=0;i<size;i++){
  tinyGraph[i]=new Image(200,100);
  tinyGraph[i].src = "http://oil-price.net/"+tinyDates[i]+"_tiny.gif";
  tinyButton_hover[i] = new Image(20, 16);
  tinyButton_hover[i].src = "http://www.oil-price.net/TINY_CHART/static/hover_"+tinyDates[i]+".png";
  tinyButtons[i] = new Image(20, 16);
  tinyButtons[i].src = "http://www.oil-price.net/TINY_CHART/static/button_"+tinyDates[i]+".png";
  }
}
var tinyCurrent_but=0;
function showTinyGraph(id){
 document.getElementById("tinyButton_"+tinyCurrent_but).src=tinyButtons[tinyCurrent_but].src;
 document.getElementById("tinyGraph").src=tinyGraph[id].src;
 document.getElementById("tinyButton_"+id).src=tinyButton_hover[id].src;
 tinyCurrent_but=id;
 return true;
};
document.writeln('<table summary=\"Crude oil and commodity prices (c) http://oil-price.net\" style=\"font-family: Arial, Helvetica, sans-serif; font-size: 12px; background-color:#efefef; border-collapse: collapse; text-align: left; border: 1px solid #000000; padding:0px; border-spacing:0px;\">');
document.writeln('<tbody style=\"padding:0px;\">');
document.writeln('<tr>');
document.writeln('<td>');
document.writeln('<table style=\"font-family: Arial, Helvetica, sans-serif; font-size: 12px; background-color:#efefef; text-align: left; border: 0px; padding:0px; \" width=\"100%\">');
document.writeln('<tr><td style=\"background-color:#cecfce; font-size: 16px; font-weight: bold; color: #000000; white-space: nowrap\" colspan=4 align=\"center\">');
document.writeln('<span style=\"color: #000000\">WTI Сырая нефть<\/span><\/td>');
document.writeln('<\/tr>');
document.writeln('<tr>');
document.writeln('<td style=\"font-size: 18px; font-weight: bold; color: #000000 text-align: left; white-space: nowrap\" >');
document.writeln('<span style=\"color: #000000\">$93.86<\/span>');
document.writeln('<\/td>');
document.writeln('<td style=\"font-size: 12px; font-weight: bold; color: green; text-align: left; white-space: nowrap\">');
document.writeln('&#9650;0.54%');
document.writeln('<\/td>');
document.writeln('<td>&nbsp; <\/td>');
document.writeln('<td style=\"font-size: 12px; font-weight: bold; color: green; text-align: left; white-space: nowrap\">');
document.writeln('<\/td>');
document.writeln('<\/tr>');
document.writeln('<\/tbody>');
document.writeln('<\/table>');
document.writeln('<\/td>');
document.writeln('<\/tr>');
document.writeln('<tr>');
document.writeln('<td>');
document.writeln('<table style=\"font-family: Arial, Helvetica, sans-serif; font-size: 12px; background-color:#efefef; border-collapse: collapse; text-align: left; border: 0px; padding:0px\">');
document.writeln('<tbody style=\"padding:0px;\">');
document.writeln('<tr style=\"padding:0px;\" valign=center><td style=\"padding:0px;\" align=center >');
document.writeln('<a target=\"_blank\" href=\"http://oil-price.net/dashboard.php?lang=ru#TINY_CHART\">');
document.writeln('<img style=\"border:0px;\" src=\"http://oil-price.net/1m_tiny.gif\" id=\"tinyGraph\" >');
document.writeln('<\/a>');
document.writeln('<\/td>');
document.writeln('<\/tr>');
document.writeln('<tr>');
document.writeln('<td>');
document.writeln('<table style=\"font-family: Arial, Helvetica, sans-serif; font-size: 12px; background-color:#efefef; border-collapse: collapse; text-align: left; border: 0px; padding:0px\" width=100% >');
document.writeln('<tbody style=\"padding:0px;\">');
document.writeln('<tr><td>');
document.writeln('<a target=\"_blank\" href=\"http://oil-price.net/dashboard.php?lang=ru#TINY_CHART\" onMouseOver=\"showTinyGraph(0);\"><img style=\"border:0px;\" src=\"http://www.oil-price.net/TINY_CHART/static/hover_1m.png\" id=\"tinyButton_0\"><\/a>');
document.writeln('<\/td>');
document.writeln('<td>');
document.writeln('<a target=\"_blank\" href=\"http://oil-price.net/dashboard.php?lang=ru#TINY_CHART\" onMouseOver=\"showTinyGraph(1);\"><img style=\"border:0px;\" src=\"http://www.oil-price.net/TINY_CHART/static/button_1q.png\" id=\"tinyButton_1\"><\/a>');
document.writeln('<\/td>');
document.writeln('<td>');
document.writeln('<a target=\"_blank\" href=\"http://oil-price.net/dashboard.php?lang=ru#TINY_CHART\" onMouseOver=\"showTinyGraph(2);\"><img style=\"border:0px;\" src=\"http://www.oil-price.net/TINY_CHART/static/button_1y.png\" id=\"tinyButton_2\"><\/a>');
document.writeln('<\/td>');
document.writeln('<td>');
document.writeln('<a target=\"_blank\" href=\"http://oil-price.net/dashboard.php?lang=ru#TINY_CHART\" onMouseOver=\"showTinyGraph(3);\"><img style=\"border:0px;\" src=\"http://www.oil-price.net/TINY_CHART/static/button_5y.png\" id=\"tinyButton_3\"><\/a>');
document.writeln('<\/td>');
document.writeln('<\/tr>');
document.writeln('<\/tbody>');
document.writeln('<\/table>');
document.writeln('<\/td>');
document.writeln('<\/tr>');
document.writeln('<\/tbody>');
document.writeln('<\/table>');
document.writeln('<\/td>');
document.writeln('<\/tr>');
document.writeln('<\/tbody>');
document.writeln('<\/table>');

