function DisplayResults( MaxWidth, DisplayCountThreshold, StylePrefix )
{
	var Poll = GetPoll();
	document.writeln( '<table cellspacing="0" cellpadding="0" class="' + StylePrefix + 'PollResultsTable">' );
	for( var o = 0; o < Poll.Options.length; o++ )
	{
		document.writeln( '<tr><td align="right" class="' + StylePrefix + 'PollResultsTextCell">' + Poll.Options[o].Text + '</td><td class="' + StylePrefix + 'PollResultsBarCell"><table cellspacing="0" cellpadding="0" class="' + StylePrefix + 'PollResultsTable"><tr><td><div class="' + StylePrefix + 'PollResultsBar" style="width:' + Math.floor( Poll.Options[o].Percent / Poll.GreatestPercent * MaxWidth ) + 'px;"><img width="1" height="1" src=""></div></td><td class="' + StylePrefix + 'PollResultsValueCell">' + ( DisplayCountThreshold >= 0 && Poll.TotalVotes >= DisplayCountThreshold ? '' + Poll.Options[o].Count + '&nbsp;/&nbsp;' : '' ) + Math.floor( Poll.Options[o].Percent ) + '%</td></tr></table></td></tr>' );
	}
	document.writeln( '</table>' + ( DisplayCountThreshold >= 0 && Poll.TotalVotes >= DisplayCountThreshold ? '<p align="right"><span class="' + StylePrefix + 'PollResultsText">' + Poll.TotalVotes + ' total votes</span></p>' : '' ) );
}

function DisplayQuestion( StylePrefix )
{
	var Poll = GetPoll();
	document.writeln( '<span class="' + StylePrefix + 'PollResultsTitle">' + Poll.Question + '</span>' );
}

function GetPoll()
{
	Poll = new Array();
	Poll['ID'] = 44;
	Poll['Question'] = 'Is Sarbanes-Oxley making IT better or worse?';
	Poll['TotalVotes'] = 0;
	Poll['GreatestCount'] = 0;
	Poll['GreatestPercent'] = 0;
	Poll['Options'] = new Array();
	Poll['Options'][0] = new Array();
	Poll['Options'][0]['Text'] = 'Better';
	Poll['Options'][0]['Count'] = 0;
	Poll['Options'][0]['Percent'] = 0;
	Poll['Options'][1] = new Array();
	Poll['Options'][1]['Text'] = 'Worse';
	Poll['Options'][1]['Count'] = 0;
	Poll['Options'][1]['Percent'] = 0;
	Poll['Options'][2] = new Array();
	Poll['Options'][2]['Text'] = 'No impact';
	Poll['Options'][2]['Count'] = 0;
	Poll['Options'][2]['Percent'] = 0;
	return Poll;
}
