function dropdown(value)
{
	document.getElementById("dropdown"+value).style.display='block';
}

function hide(value)
{
	document.getElementById("dropdown"+value).style.display='none';
}

function redirect(page)
{
	window.location = page;
}

function append(){
	
var labels=new Array();
labels[0]="Compare All Annuities";
labels[1]="Fixed Rate Annuities";
labels[2]="Fixed/Equity-Indexed Annuities";
labels[3]="Income Benefits (GMIBs)";
labels[4]="Lifetime Withdrawal Benefits (LWBs)";
labels[5]="Guaranteed Account Value (GAVs)";
labels[6]="Bonus Annuities";
labels[7]="No-Surrender Annuities";
labels[8]="No-Load Annuities";
labels[9]="Death Benefit Provisions";
labels[10]="Investment Strategies";
labels[11]="Immediate Annuities";
labels[12]="Secondary Market Annuities";
labels[13]="Equity Linked CDs";
labels[14]="What is an annuity";
labels[15]="Is an annuity suitable for me?";
labels[16]="The different types of Annuities";
labels[17]="The Annuity Qualifier";
labels[18]="Financial Self Assessment";
labels[19]="Annuity Checklist";

var links =new Array();
links[0]="compare-best-annuity-rates.html";
links[1]="fixed-annuities.html";
links[2]="compare_fixed_indexed_annuities.html";
links[3]="compare-guaranteed-minimum-income-benefits.html";
links[4]="lifetime_income_benefit.html";
links[5]="guaranteed_account_value.html";
links[6]="compare_bonus_annuities.html";
links[7]="compare_no-surrender_annuities.html";
links[8]="compare_no-load_annuities.html";
links[9]="compare-death-benefits.html";
links[10]="ca_investment_strategies.html";
links[11]="immediate-annuities.html";
links[12]="compare-secondary-market-immediate-annuities.html";
links[13]="compare_equity_linked_cds.html";
links[14]="ab1a_what_is_an_annuity.html";
links[15]="ab1b_is_an_annuity_right_for_m.html";
links[16]="types-of-annuities.html";
links[17]="ab2d_annuity_qualifier.html";
links[18]="retirement-calculator.html";
links[19]="ac_annuity_checklist.html";


var i=0;
for(i=0;i<=13;i++)
{
	
var dropDown = document.getElementById('dropdown2'); // identify <ul>
var listItem = document.createElement('li'); // create a <li> to have something to append
var listItemAnchor = document.createElement('a'); // create content for <li>
var listItemAnchorText = document.createTextNode(labels[i]); // create content for <a>
listItemAnchor.setAttribute('href', links[i]);
listItemAnchor.setAttribute('rel', 'nofollow');

if(i%2 == 0){
	listItemAnchor.setAttribute('class', 'bg'); // self-explanatory
}

// now, pull the act together
listItemAnchor.appendChild(listItemAnchorText);
listItem.appendChild(listItemAnchor);
dropDown.appendChild(listItem);
}

for(i=14;i<20;i++){
		
var dropDown = document.getElementById('dropdown1'); // identify <ul>
var listItem = document.createElement('li'); // create a <li> to have something to append
var listItemAnchor = document.createElement('a'); // create content for <li>
var listItemAnchorText = document.createTextNode(labels[i]); // create content for <a>
listItemAnchor.setAttribute('href', links[i]);
listItemAnchor.setAttribute('rel', 'nofollow');

if(i % 2 == 0){
	listItemAnchor.setAttribute('class', 'bg'); // self-explanatory
}

// now, pull the act together
listItemAnchor.appendChild(listItemAnchorText);
listItem.appendChild(listItemAnchor);
dropDown.appendChild(listItem);
}

}

function newWindow(url, width, height){
  window.open(''+url+'', 'myname','width='+width+',height='+height+',resizable=yes,scrollbars=yes');
}

function wOpen(sel){
    var filename = 'annuity-intelligence';
    if (sel == 10)
      filename = 'get-sma-buyers-guide';

	if (sel == 14)
      filename = 'get-investors-guide';
      
		window.open(''+filename+'.html?aiSelected='+sel+'', 'myname','width=850,height=600,resizable=yes,scrollbars=yes');
}

function wOpenGuide(sel){
		window.open('request-guide.html', 'myname','width=600,height=600,resizable=no,scrollbars=yes');
}

function displayFormWithArgument(param){
	 window.open('/ask-an-expert-form.html?param=', 'Ask an Expert', 'width=600,height=600,resizable=no,scrollbars=yes'); 
}

function displayForm(){
    window.open('/ask-an-expert-form.html', 'myname','width=600,height=600,resizable=no,scrollbars=yes');
}
function displayFormSC(){
    window.open('/schedule-consultation-popup.html', 'myname','width=600,height=600,resizable=no,scrollbars=yes');
}

