Deme is designed for the Chrome, Safari, and Firefox browsers. It should also work in Internet Explore 8 and above, but will have visual inconsistencies.
At the top is the Toolbar, which allows users to Log in, Search, etc. By default, the Toolbar is in “Basic Layout”, which hides the more advanced functionality. Clicking on the Gear icon at the very top left switches to “Advanced Layout”, which introduces more advanced funtionality.
Buttons from left to right:
Gear: Switches between Basic and Advanced Layout. Hidden if the user does not have permission to view the Advanced Layout. Font size: Allows the user to change the font size for all text on the screen. Search: Searches all items by name and provides a quick link to the Advanced Search interface. Login menu: Displays log in options as well as details for logged in users.
Buttons from left to right not present in the Basic Layout:
Breadcrumbs: A list showing the current item (if any), item type, and a link to all items. Actions menu: A menu of actions that apply to the current page. Actions icons: Shortcuts to some of the key actions of the Actions menu. Metadata: Opens the Metadata sidebar, which contains help and information about the current page.
After your Deme site is appropriately set up, many components can be easily customized. Be sure to log in as Admin in order to have permission to make many of these changes.
To change who can see the Advanced toolbar, you’ll need to change Advanced Layout under Global Permissions:
DjangoTemplateDocuments allow many different sections of the page to be modified. Here are the important ones:
To customize your site, you edit these different sections. To learn more about the syntax and technical details, visit [Django’s Templates Documentation](https://docs.djangoproject.com/en/1.5/ref/templates/)
Deme also comes with some sample layouts. By default they are called “Sample Layout” and “Sample Forum Layout”. Change the Default layout to one of them for a very different look and feel.
In the current layout, edit the different “blocks” to modify the site.
Adding navigation tabs:
{% block tabs-section %}
<div class="tabs-section">
<ul class="nav nav-tabs">
<li><a href="/">Home</a></li>
<li><a href="/viewing/group/5">Group</a></li>
<li><a href="...">...</a></li>
</ul>
</div>
{% endblock %}
Inserting a banner section:
{% block banner-section %}
<div class="banner-section">
<h3>Your banner text goes here</h3>
</div>
{% endblock banner-section %}
Adding custom CSS:
{% block custom_css %}
.page-layout .logo-section a.logo {
background: darkred;
}
{% endblock %}
Adding CSS/JS files:
{% block head_append %}
<link rel="stylesheet" href="http://www.yoursite.com/stylesheet.css" type="text/css">
{% endblock %}
Editing the sidebar:
{% block sidebar-section %}
<div class="sidebar-section">
<div class="panel">
<div class="panel-heading">
Resources
</div>
<ul>
<li><a href="...">Link Goes Here</a></li>
<li>...</li>
</ul>
</div>
</div>
{% endblock %}
Showing a different footer to users who aren’t the Admin:
{% block footer %}
{% if cur_agent.is_admin %}
{{ block.super }}
{% else %}
This is the footer you see when you're not the admin.
{% endif %}
{% endblock footer %}
Showing a log in form to visitors who aren’t logged in:
{% block body_wrap %}
{% if cur_agent.is_anonymous %}
{% include "demeaccount/required_login_include.html" %}
{% else %}
{{ block.super }}
{% endif %}
{% endblock body_wrap %}
Hiding chat:
{% block chat %}{% endblock %}
To show site-wide chat, you’d simply delete that line from a layout.
Assuming you’ve created a DjangoTemplateDocument item you’d like to use as your home page:
Using a DjangoTemplateDocument instead of an HtmlDocument allows editing of nearly all elements on a page instead of only the contents of the main content area.
If you have multiple domains or subdomains that point to your Deme installation, you can show different sites for each by using different Site objects. For instance, let’s say you are pointing both domain1.com and domain2.com to the same Deme installation. Let’s also say that you’ve already set up domain1.com as desired but want domain2.com to appear differently.
If you have a lot of different sites, you may wish to restrict certain items to certain groups. To do so:
If you have many items that you’d like to restrict, it’s probably easiest to use collection permissions:
If you added an item into a collection without checking Permission Enabled and want collection permissions to apply to that item, you’ll need to change that item’s Membership to the collection. To do this, open up the collection, open the Metadata panel, and select Related Data. Open up the list of Child Memberships and make sure all memberships have Permission Enabled checked.