Deme Layout

Layout None
Override default layout True
{% load item_tags %}
{% load chat_extras %}
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">

<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

{% if item %}
<title>Deme &raquo; {% viewable_name item %}{% if action_title %} &raquo; {{ action_title }}{% endif %}</title>
{% else %}
<title>Deme{% if action_title %} &raquo; {{ action_title }}{% endif %}</title>
{% endif %}


<link rel="shortcut icon" href="{% block favicon %}{% if item %}{{ item.actual_item_type|icon_url:24 }}{% else %}{{ accepted_item_type|icon_url:24 }}{% endif %}{% endblock favicon %}" type="image/x-icon" />
<!--<link rel="shortcut icon" href="{% media_url "favicon.ico" %}" type="image/x-icon" />-->

{% universal_edit_button %}

<link rel="stylesheet" href="{% media_url "stylesheets/blueprint/screen.css" %}" type="text/css" media="screen, projection" />
<link rel="stylesheet" href="{% media_url "stylesheets/blueprint/print.css" %}" type="text/css" media="print" />
<!--[if IE]>
<link rel="stylesheet" href="{% media_url "stylesheets/blueprint/ie.css" %}" type="text/css" media="screen, projection" />
<![endif]-->
<link href="{% media_url "stylesheets/base.css" %}" media="all" rel="Stylesheet" type="text/css" />

<script type="text/javascript" src="{% media_url "javascripts/jquery-1.3.2.min.js" %}"></script>

<script type="text/javascript" src="{% media_url "javascripts/jquery-ui-1.8.18.custom.min.js" %}"></script>
<link href="{% media_url "stylesheets/smoothness/jquery-ui-1.8.18.custom.css" %}" media="all" rel="Stylesheet" type="text/css" />

<script type="text/javascript" src="{% media_url "javascripts/grid.locale-en.js" %}"></script>
<script type="text/javascript" src="{% media_url "javascripts/jquery.jqGrid.min.js" %}"></script>
<link href="{% media_url "stylesheets/ui.jqgrid.css" %}" media="all" rel="Stylesheet" type="text/css" />

<script type="text/javascript" src="{% media_url "javascripts/fg.menu.js" %}"></script>
<script type="text/javascript">
$(document).ready(function () {
$('#showhidetarget').hide();

$('a#showhidetrigger').click(function () {
$('#showhidetarget').toggle(400);

if($.browser.safari)
{
$("#showhidetarget").html("<p>For Safari users: Safari currently does not support the ability to go fullscreen.</p>");
}
if($.browser.mozilla)
{
$("#showhidetarget").html("<p>For Firefox user: Click on the View menu, located at the top of your browser window. When the drop-down menu appears, select the option labeled Full Screen.</p>");
}
if($.browser.msie)
{
$("#showhidetarget").html("<p>For Internet Explorer users: Click on the Tools menu, located at the top of your browser window. When the drop-down menu appears, select the option labeled Full Screen.</p>");

}
if(navigator.userAgent.toLowerCase().indexOf('chrome') > -1)
{
$("#showhidetarget").html("<p>For Chrome users: Click on the Chrome \"wrench\" icon, located in the upper right hand corner of your browser window. When the drop-down menu appears, select the choice labeled Full Screen.</p>");
}
return false;
});
});
</script>


</script>
<link href="{% media_url "stylesheets/fg.menu.css" %}" media="screen" rel="stylesheet" type="text/css" />
<!-- style exceptions for IE 6 -->
<!--[if IE 6]>
<style type="text/css">
.fg-menu-ipod .fg-menu li { width: 95%; }
.fg-menu-ipod .ui-widget-content { border:0; }
</style>
<![endif]-->

{% if item %}
<link rel="alternate" type="application/rss+xml" title="Action notice feed" href="{% url item_url viewer=viewer_name,action="show",noun=item.pk,format="rss" %}" />
{% endif %}
{% ifequal action 'list' %}
<link rel="alternate" type="application/rss+xml" title="Item feed" href="{% url item_type_url viewer=viewer_name,action="list",format="rss" %}" />
{% endifequal %}
<script type="text/javascript">
// from http://www.filamentgroup.com/examples/buttonFrameworkCSS/
$(function(){
//all hover and click logic for buttons
$(".fg-button:not(.ui-state-disabled)")
.hover(
function(){
$(this).addClass("ui-state-hover");
},
function(){
$(this).removeClass("ui-state-hover");
}
)
.mousedown(function(){
$(this).parents('.fg-buttonset-single:first').find(".fg-button.ui-state-active").removeClass("ui-state-active");
if( $(this).is('.ui-state-active.fg-button-toggleable, .fg-buttonset-multi .ui-state-active') ){ $(this).removeClass("ui-state-active"); }
else { $(this).addClass("ui-state-active"); }
})
.mouseup(function(){
if(! $(this).is('.fg-button-toggleable, .fg-buttonset-single .fg-button, .fg-buttonset-multi .fg-button') ){
$(this).removeClass("ui-state-active");
}
});
});

// To give the gray "Search" text in the search box
$(document).ready(function () {
var search_box_changed = {% if search_query %}true{% else %}false{% endif %};
var search_box = document.getElementById('search_box');
search_box.onfocus = function(e){
if (!search_box_changed) {
search_box_changed = true;
search_box.value = '';
search_box.style.color = 'inherit';
}
};
search_box.onblur = function(e){
if (search_box.value == '') {
search_box_changed = false;
search_box.value = 'Search';
search_box.style.color = '#777';
}
};
search_box.onblur();

var cache = {};
var last_xhr;
$(search_box).autocomplete({
minLength: 0,
select: function(event, ui) {
window.location.href = ui.item.url;
},
source: function(request, response) {
var term = request.term;
if (term in cache) {
response(cache[term]);
return;
}
last_xhr = $.getJSON('{% url item_type_url viewer="item",action="grid",format="json" %}', {rows:10, page:1, sidx:"name", sord:"asc", fields:"name", searchOper:"cn", searchField:"name", searchString:term}, function(data, status, xhr) {
var normalized_data = $.map(data["rows"], function(x){ var cell = $(x["cell"][0]); return {value: cell.text(), url: cell[0].href} });
cache[term] = normalized_data;
if (xhr !== last_xhr) {
response(normalized_data);
}
});
},
});
});
</script>

<script type="text/javascript">

function resizeText(multiplier) {
if (document.body.style.fontSize == "") {
document.body.style.fontSize = ".8em";
}
document.body.style.fontSize = parseFloat(document.body.style.fontSize) + (multiplier * 0.2) + "em";
}
</script>
<script type="text/javascript">
function unhide(divID) {
var item = document.getElementById(divID);
if (item) {
item.className=(item.className=='hidden')?'unhidden':'hidden';
}
}
</script>
<script type="text/javascript">
function toggleNewItemMenu(className){
var menu = "#" + className;
if ($(menu).is(":hidden")) {
$(menu).slideDown("slow");
} else {
$(menu).slideUp("slow");
}
};
</script>
<!--
<script type="text/javascript">
function toggleChat(className){
var chat = "#" + className;
if ($(chat).is(":hidden")) {
$(chat).slideDown("slow");
$("#chat_messages").scrollTop($("#chat_messages")[0].scrollHeight);
$("#expandChatButton").attr("class", "ui-icon ui-icon-circle-triangle-s");
} else {
$(chat).slideUp("slow");
$("#expandChatButton").attr("class", "ui-icon ui-icon-circle-triangle-n");
}
};
</script>
-->

</head>

<body>

{% if item %}
<div id="fixed_right_pane" style="position: fixed; overflow-y: auto; top: 90px; bottom: 10px; right: 10px; width: 0%; display: none;">
<div class="ui-helper-clearfix" style="font-size: 60%; float: right;">

<a href="#" id="increasebutton" onclick="increase_column_right(); return false;" class="fg-button ui-state-default fg-button-icon-solo ui-corner-all" title="Show"><span class="ui-icon ui-icon-arrowthickstop-1-w"></span> Show</a>
<a href="#" id="decreasebutton" onclick="decrease_column_right(); return false;" class="fg-button ui-state-default fg-button-icon-solo ui-corner-all" title="Hide"><span class="ui-icon ui-icon-arrowthickstop-1-e"></span> Hide</a>
<a href="#" id="closebutton" onclick="hide_fixed_right_pane(); return false;" class="fg-button ui-state-default fg-button-icon-solo ui-corner-all" title="Close"><span class="ui-icon ui-icon-circle-close"></span> Close</a>
</div>
<div style="clear: both;"></div>
<div class="metadata_content metadata_content_item_details" style="display: none;">
</div>
{% if no_side_comment_box %}
{% else %}
<div class="metadata_content metadata_content_comments" style="display: none;">
</div>
{% endif %}
<div class="metadata_content metadata_content_action_notices" style="display: none;">
</div>
<div class="metadata_content metadata_content_versions" style="display: none;">
</div>
<div class="metadata_content metadata_content_related_items" style="display: none;">
</div>
<div class="metadata_content metadata_content_permissions" style="display: none;">
</div>
</div>
{% endif %}

<div class="site_outer">
<div class="site_inner" {% if item %}style="width: 97%;"{% endif %}>

<div style="position: fixed; top: 0px; left: 215px; right: 10px; height: 50px; padding: 10px; background: #fff; border: thin ridge gray; -moz-box-shadow: 5px 3px 3px #ccc; -webkit-box-shadow: 5px 3px 3px #ccc;box-shadow: px 3px 3px #ccc;">

<div style="float: right;">
<div style="float: left;" id="actions_wrapper">
<span style="text-size: larger; font-weight: bold;">Actions:</span>
<br />
<div id="actions_menu_wrapper">
{% actionsmenu %}
</div>
<script type="text/javascript">
$(function(){
if ($.trim($('#actions_menu_wrapper').text()) == '') {
$('#actions_wrapper').hide();
}
});
</script>
</div>

{% if item %}
<script type="text/javascript">
$(function(){
var already_loaded_metadata_names = {};
$('#metadata_menu_link').fgmenu({
content: $('#metadata_menu_link').next().html(),
showSpeed: 50,
fixedPosition: true,
});
var menu = allUIMenus[allUIMenus.length - 1];
menu.chooseItem = function(item){
var text = $(item).html();
menu.kill();
$('#metadata_menu_link .metadata_menu_name').text(text);
var metadata_menu_name = $(item).attr('id').replace('metadata_menu_', '');
$('.metadata_content').hide();
$('.metadata_content_' + metadata_menu_name).show();
if (!$('#fixed_right_pane').is(':visible')) {
$('#fixed_right_pane').show();
increase_fixed_right_pane(38, 10);
}
if (!(metadata_menu_name in already_loaded_metadata_names)) {
already_loaded_metadata_names[metadata_menu_name] = true;
$('.metadata_content_' + metadata_menu_name).html("Loading...");
jQuery.ajax({
url: "{% url item_url viewer=viewer_name,noun=item.pk,action="metadata" %}?name=" + metadata_menu_name + '&amp;original_full_path={{ full_path|escapejs }}',
success: function(data) {
$('.metadata_content_' + metadata_menu_name).html(data);
}
});
}
};
{% if default_metadata_menu_option %}
var item = $('#metadata_menu_{{default_metadata_menu_option}}');
menu.chooseItem(item);
{% endif %}
});
</script>
<div style="float: left;">
<span style="text-size: larger; font-weight: bold;">Metadata:</span>
<br />
<a href="#" class="fg-button fg-button-icon-right ui-widget ui-state-default ui-corner-all" id="metadata_menu_link"><span class="ui-icon ui-icon-triangle-1-s"></span><span class="metadata_menu_name">------</span></a>
<div style="display: none;">
<ul style="font-size: 85%;">
<li><a href="#" onclick="return false;" id="metadata_menu_item_details">Item details</a></li>
{% if no_side_comment_box %}
{% else %}
<li><a href="#" onclick="return false;" id="metadata_menu_comments">Comments</a></li>
{% endif %}
<li><a href="#" onclick="return false;" id="metadata_menu_action_notices">Action notices</a></li>
<li><a href="#" onclick="return false;" id="metadata_menu_versions">Versions</a></li>
<li><a href="#" onclick="return false;" id="metadata_menu_related_items">Related items</a></li>
<li><a href="#" onclick="return false;" id="metadata_menu_permissions">Permissions</a></li>
</ul>
</div>
</div>
{% endif %}

<div style="float: left;">
<span style="text-size: larger; font-weight: bold;">Account:</span>
<br />
{% login_menu %}
</div>

</div>

<form method="get" action="{% url item_type_url viewer="item" %}" style="display: inline; border-bottom: 20px;">
<input type="search" id="search_box" name="q" value="{{ search_query }}" style="width: 20em;" />
{# TODO add magnifying glass #}
</form>
<br>
<br>
<div class="bs" >
{% crumbs %}
</div>


</div>

<div class="HiddenMenu" id="HiddenNewItemMenu" style="position: fixed; top: 73px; left: 220px; right: 20px; padding: 10px; background: #fff; border: thin ridge gray; -moz-box-shadow: 5px 3px 3px #ccc; -webkit-box-shadow: 5px 3px 3px #ccc;box-shadow: px 3px 3px #ccc; display: none;">
<div style="float:right; height: 5px; font-size: 20%;">
<a href="#" id="closebutton" onclick="toggleNewItemMenu('HiddenNewItemMenu'); return false;" class="fg-button ui-state-default fg-button-icon-solo ui-corner-all" title="Close"><span class="ui-icon ui-icon-close"></span> Close</a>
</div>
<div style="float:left;">
{% defaultcreateitemtypes %}
<div class="create_image" style="float: left; margin-right: 2em;">
<a href="{% url item_type_url viewer=create_item_viewer_name,action="new"%}" class="img_link"><img src="{{create_item_type|icon_url:64}}" title="Create new {% item_type_verbose_name create_item_type %}" />New {% item_type_verbose_name create_item_type %}</a>
</div>
{% enddefaultcreateitemtypes %}
<a href="{% url item_type_url viewer="item",action="newother"%}" class="fg-button fg-button-icon-right ui-widget ui-state-default ui-corner-all poll" style="margin-top: 20px;">Other</a>
<div style="clear: both;"></div>
</div>


<div style="clear: both;"></div>
</div>

<script type="text/javascript">
function increase_fixed_right_pane(percent_incr, min_width_percent) {
var left_width_text = $('.site_inner')[0].style.width;
var right_width_text = $('#fixed_right_pane')[0].style.width;
var left_width = parseInt(left_width_text.replace("%", ""), 10);
var right_width = parseInt(right_width_text.replace("%", ""), 10);
var new_left_width = left_width - percent_incr;
var new_right_width = right_width + percent_incr;
var new_left_width_text = new_left_width + "%";
var new_right_width_text = new_right_width + "%";
if (new_left_width > min_width_percent && new_right_width > min_width_percent) {
$('.site_inner')[0].style.width = new_left_width_text;
$('#fixed_right_pane')[0].style.width = new_right_width_text;
} else {
hide_fixed_right_pane();
}
}
function increase_column_right() {
increase_fixed_right_pane(3, 10);
}
function decrease_column_right() {
increase_fixed_right_pane(-3, 10);
}
function hide_fixed_right_pane() {
var left_width_text = $('.site_inner')[0].style.width;
var right_width_text = $('#fixed_right_pane')[0].style.width;
var left_width = parseInt(left_width_text.replace("%", ""), 10);
var right_width = parseInt(right_width_text.replace("%", ""), 10);
var new_left_width = left_width + right_width;
var new_left_width_text = new_left_width + "%";
$('#fixed_right_pane').hide();
$('.site_inner')[0].style.width = new_left_width_text;
$('#fixed_right_pane')[0].style.width = "0%";
$('#metadata_menu_link .metadata_menu_name').html('------');
}

function openCommentDialog(name)
{
var dialogBox = $('#' + name);
dialogBox.dialog({
autoOpen: false,
bgiframe: true,
modal: true,
close: function(event, ui) {dialogBox.dialog('destroy')}
});
dialogBox.dialog('open');
}
function displayHiddenDiv(name)
{
var hiddenDiv = $('#' + name);
hiddenDiv.show();
}
</script>

<div class="content_box">

<table cellspacing="0">
<tr>
<td style="vertical-align: top; width: 15%; padding:0;" id="left_table_column">
<div style="margin-bottom: 10px;">
<a href="/"><img src="/static/filedocument/2010/10/26/deme-logo-website_.gif" alt="Deme Logo" style="height: 100px; width: 200px; border: 1px solid #aaa; background-color: #fff; -moz-border-radius: 8px; -webkit-border-radius: 8px;" /></a>
</div>
<div class="ui-widget-header ui-corner-top ui-helper-clearfix" style="padding: 5px;">
Recently Viewed
</div>
<div class="ui-widget-content ui-corner-bottom ui-helper-clearfix" style="padding: 5px; margin-bottom: 10px;">
{% recently_viewed %}
</div>
<div class="ui-widget-header ui-corner-top ui-helper-clearfix" style="padding: 5px;">
Navigation
</div>
<div class="ui-widget-content ui-corner-bottom ui-helper-clearfix" style="padding: 5px; margin-bottom: 10px;">
<ul style="list-style-type: none; margin: 0; padding: 0;">
<li{% ifequal full_path "/"%} style="font-weight: bold;"{% endifequal %}><a href="/">Home</a></li>
<li{% ifequal action "list" %}{% ifequal viewer_name "item" %} style="font-weight: bold;"{% endifequal %}{% endifequal %}><a href="{% url item_type_url viewer="item" %}">Items</a></li>
<li><a href="http://deme.stanford.edu/static/docs/index.html">Docs</a></li>
</ul>
</div>
</td>
<td style="vertical-align: top; width: 85%; padding:0;" id="center_table_column">
<div style="margin-top: 80px;">
{% if layout_permissions_problem %}
<div style="color: #a00; padding: 15px; margin: 15px; border: thin dotted #a00; text-align: center;">
Permissions Error: You are not authorized to view the layout, so this page is being displayed in the default layout.
</div>
{% endif %}
<table style="margin-bottom: 0;">
<tr>
<td style="vertical-align: bottom; padding: 0; padding-left: 5px;" colspan="2">
<div style="clear: both;"></div>
<div class="title">
{% block title %}
{% if item %}
<img src="{{ item.actual_item_type|icon_url:24 }}" title="{% item_type_verbose_name item %}" /> {% viewable_name item %}{% if action_title %} &raquo; {{ action_title }}{% endif %}
{% else %}
<img src="{{ accepted_item_type|icon_url:24 }}" title="{% item_type_verbose_name accepted_item_type %}" /> {% if action_title %}{{ action_title }}{% else %}{{ accepted_item_type_name_plural|capfirst }}{% endif %}
{% endif %}
{% endblock title %}
</div>
</td>
</tr>
</table>
<div style="padding: 0 5px 0 5px;">
{% block content %}
{% endblock %}
</div>
</div>
</td>
</tr>
</table>

</div>
<div style="clear: both;"></div>
<!--
<div class ="chat" style="width: 200px; margin: 0; position: fixed; bottom: 0;">
<div class="ui-widget-header ui-corner-top ui-helper-clearfix" id="chatHeader" style="padding: 5px;">
Chat
<a id="expandChat" onclick="toggleChat('chatBody'); return false;" class="fg-button ui-state-default fg-button-icon-solo ui-corner-all" title="Expand_Chat" style="float: right; height: 10px;"><span class="ui-icon ui-icon-circle-triangle-n" id="expandChatButton" style= "height: 20px;"></span>Expand Chat</a>


</div>
<div class="ui-widget-content ui-corner-bottom ui-helper-clearfix" id="chatBody" style="padding: 5px; display:none;">
{% chat_box %}
</div>
</div>
-->

<div class="footer">
<p>
<b>Desktop Browser</b>
{% if item %}
|
<a href="{% url item_url viewer=viewer_name,action="show",noun=item.pk,format="rss" %}">RSS</a>
{% endif %}
{% ifequal action 'list' %}
|
<a href="{% url item_type_url viewer=viewer_name,action="list",format="rss" %}?{{ query_string }}">RSS</a>
{% endifequal %}
|
<a href="#" onclick="resizeText(1); return false;">Increase text size</a>
|
<a href="#" onclick="resizeText(-1); return false;">Decrease text size</a>
|
<a href="#" id="showhidetrigger">Fullscreen</a>
|
<a href="javascript:function Sel(w){var s = '',i=0; try{if (w.getSelection) s = w.getSelection(); else s = w.document.getSelection(); i=w.frames.length; }catch(e){} while (((s == '')||(s == null)) && i--){s=Sel(w.frames[i]);}if (s == null) s='';return ''+s;};function Pop(url,title){win=window.open(url,title,'toolbar=no,width=800,height=600,scrollbars=yes,resizable=yes'); win.focus();};var s=Sel(this);if (s=='') void(s=prompt('Type a word for look up',''));if(s!=null) void(Pop('http://www.wordsmyth.net/?level=3&m=wn&ent='+escape(s), 'w_mini'));" class="wedt"><span>Dictionary/Thesaurus</span></a>
|
<a href="#" onclick="$('#google_translate_dialog').dialog({close: function(event, ui) {$('#google_translate_dialog').dialog('destroy')}}); return false;">Translate</a>
<div id="google_translate_dialog" title="Translate" style="display: none;">
<div id="google_translate_element">
</div>
</div>
<script>
function googleTranslateElementInit() {
new google.translate.TranslateElement({
pageLanguage: 'en',
layout: google.translate.TranslateElement.InlineLayout.SIMPLE
}, 'google_translate_element');
}
</script><script src="//translate.google.com/translate_a/element.js?cb=googleTranslateElementInit"></script>
</p>
<p>Copyright &copy;2008-{% now "Y" %} to Deme | <a href="http://github.com/mikemintz/deme/tree/master">Source Code</a> <span class="pipe">|</span> <a href="/viewing/group/23">Authors</a> | <a href="http://twitter.com/#!/DemeTeam">Twitter</a> | <a href="{% url item_type_url viewer="item",action="admin" %}">Admin</a> | <a href="{% url item_type_url viewer="item",action="recentchanges" %}">Recent Changes</a></p>
</div>
<div id="showhidetarget">

<p>For Internet Explorer users: Click on the Tools menu, located at the top of your browser window. When the drop-down menu appears, select the option labeled Full Screen.</p>
<p>For Chrome users:Click on the Chrome "wrench" icon, located in the upper right hand corner of your browser window. When the drop-down menu appears, select the choice labeled Full Screen.</p>
<p>For Firefox user:Click on the View menu, located at the top of your browser window. When the drop-down menu appears, select the option labeled Full Screen.</p>
<p>For Safari users: Safari currently does not support the ability to go fullscreen.</p>
</div>
</div>
</div>


</body>

</html>

For Internet Explorer users: Click on the Tools menu, located at the top of your browser window. When the drop-down menu appears, select the option labeled Full Screen.

For Chrome users:Click on the Chrome "wrench" icon, located in the upper right hand corner of your browser window. When the drop-down menu appears, select the choice labeled Full Screen.

For Firefox user:Click on the View menu, located at the top of your browser window. When the drop-down menu appears, select the option labeled Full Screen.

For Safari users: Safari currently does not support the ability to go fullscreen.