| Name
| Term
| Party
| Die in office
|
| George Washington
| 1, 2
| No Party
| no
|
| John Adams
| 3
| Federalist
| no
|
| Thomas Jefferson
| 4, 5
| Democratic-Republican
| no
|
| James Madison
| 6, 7
| Democratic-Republican
| no
|
| James Monroe
| 8, 9
| Democratic-Republican
| no
|
| John Quincy Adams
| 10
| Democratic-Republican
| no
|
| Andrew Jackson
| 11, 12
| Democratic
| no
|
| Martin Van Buren
| 13
| Democratic
| no
|
| William Harrison
| 14
| Whig
| no
|
| John Tyler
| 14
| Whig
| no
|
| James Polk
| 15
| Democratic
| no
|
| Zachary Taylor
| 16
| Whig
| yes
|
| Millard Fillmore
| 16
| Whig
| no
|
| Franklin Pierce
| 17
| Democratic
| no
|
| James Buchanan
| 18
| Democratic
| no
|
| Abraham Lincoln
| 19, 20
| Republican
| yes
|
| Andrew Johnson
| 20
| Democratic
| no
|
| Ulysses Grant
| 21, 22
| Republican
| no
|
| Rutherford Hayes
| 23
| Republican
| no
|
| James Garfield
| 24
| Republican
| yes
|
| Chester Arthur
| 24
| Republican
| no
|
| Grover Cleveland
| 25
| Democratic
| no
|
| Benjamin Harrison
| 26
| Republican
| no
|
| Grover Cleveland
| 27
|
| no
|
| William McKinley
| 28, 29
| Republican
| yes
|
| Theodore Roosevelt
| 29, 30
| Republican
| no
|
| William Taft
| 31
| Republican
| no
|
| Woodrow Wilson
| 32, 33
| Democratic
| no
|
| Warren Harding
| 34
| Republican
| yes
|
| Calvin Coolidge
| 34, 35
| Republican
| no
|
| Herbert Hoover
| 36
| Republican
| no
|
| Franklin D. Roosevelt
| 37, 38, 39, 40
| Democratic
| yes
|
| Harry Truman
| 40, 41
| Democratic
| no
|
| Dwight Eisenhower
| 42, 43
| Republican
| no
|
| John F. Kennedy
| 44
| Democratic
| yes
|
| Lyndon Johnson
| 44, 45
| Democratic
| no
|
| Richard Nixon
| 46, 47
| Republican
| no
|
| Gerald Ford
| 47
| Republican
| no
|
| Jimmy Carter
| 48
| Democratic
| no
|
| Ronald Reagan
| 39, 50
| Republican
| no
|
| George H.W. Bush
| 51
| Republican
| no
|
| Bill Clinton
| 52, 53
| Democratic
| no
|
| George W. Bush
| 54, 55
| Republican
| no
|
try {
(function() {
SimileAjax.History.enabled = false;
var presidents = [];
var table = document.getElementById("data-table");
var rows = table.rows;
var cleanString = function(s) {
return s.replace(/^\s+/g, "").replace(/\s+$/g, "");
}
for (var i = 1; i != rows.length; i++) {
var row = rows[i];
var cells = row.cells;
var item = {
type: "President",
label: cleanString(cells[0].innerHTML),
term: eval("[ " + cells[1].innerHTML + " ]"),
party: cleanString(cells[2].innerHTML),
dieInOffice: cleanString(cells[3].innerHTML)
};
presidents.push(item);
}
var configuration = {
BrowseEngine: {
facets: [
"religion",
"party",
"dieInOffice"
]
},
ItemView: {
//viewSelector: function(itemID, exhibit) { return "president.xml"; }
},
ViewPanel: {
views: [
{ constructor: Exhibit.TileView,
configuration: {
orders: [
"term"
],
possibleOrders: [
"party",
"term"
]
}
}
],
initialView: 1
}
};
table.style.display = "none";
var exhibit = Exhibit.create(
document.getElementById("control-panel"),
document.getElementById("browse-panel"),
document.getElementById("view-panel"),
configuration
);
exhibit.getDatabase().loadProperties({
'term': {
valueType: "number"
}
}, document.location.href);
exhibit.getDatabase().loadItems(presidents, document.location.href);
exhibit.getBrowseEngine().setRootCollection(exhibit.getDatabase().getSubjects("President", "type"));
window.exhibit = exhibit;
})();
} catch (e) { console.log(e); }