/* Example:

'gerasimov' :
{'heading' : 'Sergey Gerasimov, MFE \'07',
'link_name' : 'gerasimov',
'teaser' : '"After completing my MBA, I wanted to study further the mathematics of finance and to link it to my background in computer science.  Haas\' very rigorous MFE program provides all of the courses required for a career in quantitative finance.  It matched my professional objectives and is sufficiently challenging to ensure the future success of its graduates"',
'internship' : 'Fixed Income and Equity Linked Research Department<br />Merrill Lynch<br />New York',
'current' : 'Associate, Asset Backed Securities<br />ORIX Capital Markets<br />Dallas, Texas'}

REMEMBER: You must have a comma between each profile definition but not after the last one!

REMEMBER: If you use single quotes in the profile teaser, you have to put a forward slash first:
ex: 'teaser' : 'My friends don\'t understand how great Haas is.'

To add a new profile, add a comma after the curly brace of the last one, and paste this code in after:
	'NAME' :
	{'heading' : '',
	'link_name' : '',
	'teaser' : '',
	'internship' : '',
	'current' : ''}
	
Put the same value in NAME as you do after link_name.  This is so that you can target small subsets of
profiles on some pages.

The 'teaser', 'internship', 'current' fields are optional; leave blank if you don't want one

Currently the list is organized alphabetically.  If you insert a profile in the middle somewhere, make sure
that you have a comma after the profile's final curly brace!  If you insert at the end, make sure there is
no comma!
	
To change the display code that's written to the page, edit the display_profile() function at the bottom of
this document.
*/

var profiles = {
	'abbasi' :
	{'heading' : 'Yousuf Abbasi, MFE \'07',
	'link_name' : 'abbasi',
	'teaser' : '',
	'internship' : '',
	'current' : 'Associate, Asset Backed Securities<br />ORIX Capital Markets<br />Dallas, Texas'},
	
	'barone' :
	{'heading' : 'Luca Barone, MFE \'05',
	'link_name' : 'barone',
	'teaser' : '',
	'internship' : '',
	'current' : 'Exotic Credit Derivatives Sales Strategist, FICC<br />Goldman Sachs International<br />London, UK'},
	
	'cowan' :
	{'heading' : 'Andrew Cowan , MFE \'08',
	'link_name' : 'cowan',
	'teaser' : '',
	'internship' : 'Goldman Sachs, NY<br />Special Situations Fund',
	'current' : ''},
	
	'erdmann' :
	{'heading' : 'Shannon Erdmann<br />MFE \'08',
	'link_name' : 'erdmann',
	'teaser' : '',
	'internship' : 'Associate, Equity<br />Lehman Brothers<br />New York, New York',
	'current' : ''},
	
	'gilliland' :
	{'heading' : 'Jim Gilliland<br />MFE \'02',
	'link_name' : 'gilliland',
	'teaser' : '',
	'internship' : '',
	'current' : 'Head of International Fixed Income Investments<br />Barclay\'s Global Investments<br />San Francisco, California'},
	
	'heuser' :
	{'heading' : 'Matthias Heuser, MFE \'03',
	'link_name' : 'heuser',
	'teaser' : '',
	'internship' : '',
	'current' : 'Current Position: Senior Associate, Risk Management &amp; FIG<br />McKinsey &amp; Company, Inc.<br />Hamburg'},
	
	'kahn' :
	{'heading' : 'Ronald N. Kahn, Adjunct Professor',
	'link_name' : 'kahn',
	'teaser' : 'Adjunct Professor<br />Managing Director<br />Global Head of Advanced Equity Strategies<br />Barclays Global Investors<br />San Francisco, California',
	'internship' : '',
	'current' : ''},
	
	'macdonald' :
	{'heading' : 'Geoff MacDonald, MFE \'06',
	'link_name' : 'macdonald',
	'teaser' : '',
	'internship' : '',
	'current' : 'Associate, FICC Strategies America<br />Special Situations Group<br />Goldman Sachs<br />New York'},
	
	'mehta' :
	{'heading' : 'Swati Mehta, MFE \'07',
	'link_name' : 'mehta',
	'teaser' : '',
	'internship' : '',
	'current' : 'Barclays Capital'},
	
	'rodriguez' :
	{'heading' : 'Matthew Rodriguez, MFE \'04',
	'link_name' : 'rodriguez',
	'teaser' : '',
	'internship' : '',
	'current' : 'Associate, Portfolio Management Group<br />BlackRock<br />New York City'},
	
	'rubinstein' :
	{'heading' : 'Mark Rubinstein, Professor',
	'link_name' : 'rubinstein',
	'teaser' : 'Professor Mark Rubinstein (The Paul Stephens Professor of Applied Investment Analysis) teaches two core courses in the MFE program, Fundamentals of Investments and Derivatives: Economic Concepts.',
	'internship' : '',
	'current' : ''},
	
	'tchikanda' :
	{'heading' : 'Serge Tchikanda, MFE \'07',
	'link_name' : 'tchikanda',
	'teaser' : '',
	'internship' : '',
	'current' : 'Bloomberg, New York'},
	
	'walker' :
	{'heading' : 'Courtney Walker, MFE \'07',
	'link_name' : 'walker',
	'teaser' : '',
	'internship' : '',
	'current' : 'Portfolio Associate<br />PM Trade Support<br />PIMCO, CA'},
	
	'wang' :
	{'heading' : 'Irene Wang<br />MFE \'07',
	'link_name' : 'wang',
	'teaser' : '',
	'internship' : '',
	'current' : 'Global Tactical Asset Allocation Research<br />Mellon Capital Management<br />San Francisco'},
	
	'wong' :
	{'heading' : 'Kenny Wong, MFE \'07',
	'link_name' : 'wong',
	'teaser' : '',
	'internship' : '',
	'current' : 'Associate, Fixed Income <br />UBS <br />Hong Kong'},
	
	'wong-erik' :
	{'heading' : 'Erik Wong, MFE \'06',
	'link_name' : 'wong-erik',
	'teaser' : '',
	'internship' : '',
	'current' : 'Associate, Quantitative Credit Strategy<br />Lehman Brothers<br />New York'},
	
	'xu' :
	{'heading' : 'Wanling Xu, MFE \'08',
	'link_name' : 'xu',
	'teaser' : '',
	'internship' : '',
	'current' : 'Strategist, Fixed Income<br />Citigroup<br />New York, New York'},
	
	'zambrana-rojas' :
	{'heading' : 'Christian Zambrana-Rojas, MFE \'08',
	'link_name' : 'zambrana-rojas',
	'teaser' : '',
	'internship' : '',
	'current' : 'Associate, Credit Derivatives Research<br />Lehman Brothers<br />New York, New York'}
};

/*
The following code selects a random profile to display, and controls how they are formatted

'toRoot' is required; a relative path to the root of the site
	'../' for example, if the page is in a sub-directory
'subset' is an optional comma deliminited list of profiles to select from (uses whatever's in the NAME slot above)
	'ortiz, tadelis, kulka, walling, penzini' for example
*/

function display_profile(toRoot, subset) {
	var subset = (subset == null) ? false : subset;
	var profile_group = new Array();
	if (subset) {
		subset = subset.split(/, ?/);
		for (var i = 0; i < subset.length; i++) {
			profile_group.push(profiles[subset[i]]);
		}
	} else {
		for (var profile in profiles) {
			profile_group.push(profiles[profile]);
		}
	}
	var number = Math.floor(Math.random()*profile_group.length);
	var name = profile_group[number].link_name;
	var heading = profile_group[number].heading;
	var teaser = profile_group[number].teaser;
	var internship = (profile_group[number].internship != '' ? profile_group[number].internship : false);
	var current = (profile_group[number].current != '' ? profile_group[number].current : false);
	
	var body = '<div class="profile">' +
			'<a class="noborder" href="' + toRoot + 'profiles/' + name + '.html" onclick="return popCenter(this.href, \'profile\', 448, 600);"><img src="' + toRoot + 'images/profiles/' + name + '_big.jpg" alt="' + name.replace(/<br( \/)?>/gi, ', ') + '" border="0" /></a>' +
		'<p><a href="' + toRoot + 'profiles/' + name + '.html" onclick="return popCenter(this.href, \'profile\', 448, 600);"><strong>' + heading + '</strong></a></p>';
	if (teaser) {
		body += '<p>' + teaser + '</p>';
	}
	if (internship) {
		body += '<p><strong>MFE Internship:</strong><br />' + internship + '</p>';
	}
	if (current) {
		body += '<p><strong>Current Position:</strong><br />' + current + '</p>';
	}
	body += '</div>';
	document.getElementById('supplement').innerHTML = body;
}