lodgeit-main / lodgeit / templates / layout.html

Full commit
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    <title>{{ page_title|e }} | LodgeIt!</title>
    <link rel="stylesheet" href="{{ url_for ('static', filename='style.css') }}" type="text/css">
    <link rel="stylesheet" href="{{ url_for('static', filename='print.css') }}" type="text/css" media="print">
    <link rel="stylesheet" href="{{ url_for('static', filename='redmond/jquery-ui-1.8.7.custom.css') }}" type="text/css">
    <script type="text/javascript" src="{{ url_for ('static', filename='jquery-1.4.4.min.js') }}"></script>
    <script type="text/javascript" src="{{ url_for ('static', filename='jquery-ui-1.8.7.custom.min.js') }}"></script>
    <script type="text/javascript" src="{{ url_for ('static', filename='cookie.js') }}"></script>
    <script type="text/javascript" src="{{ url_for ('static', filename='lodgeit.js') }}"></script>
    {%- if css %}
    <style type="text/css">
      {{ css|e }}
    {%- endif %}
    <div class="page">
      <div id="header"><h1>Lodge It</h1></div>
      <ul id="navigation">
      {%- for href, id, caption in [
        (url_for('pastes.new_paste'), 'new', _('New')),
        (url_for('pastes.show_all'), 'all', _('All')),
        (url_for('static.about'), 'about', _('About')),
        (url_for(''), 'help', '?')
      ] %}
        <li{% if active_page == id %} class="active"{% endif %}>
          <a href="{{ href|e }}">{{ caption|e }}</a>
      {%- endfor %}
      {# <ul id="languages">
      {% for lang, name in i18n_languages %}
        <li{% if request.locale.language == lang %} class="active"{% endif %}>
          <a href="{{ url_for('pastes.set_language', lang=format(lang)) }}"><img alt="{{ lang }}" src="{{ url_for('static', filename='flags/%s.png'|format(lang)) }}"></a>
      {% endfor %}
      </ul> #}
      <div class="content">
        <h2>{{ page_title|e }}</h2>
        {%- set new_replies = get_new_replies() %}
        {%- if new_replies %}
          <div class="notification">
            <h3>{% trans %}Someone Replied To Your Paste{% endtrans %}</h3>
            {% for paste in new_replies %}
            <p>{% trans date=paste.pub_date|datetimeformat,
                        paste_url_for=url_for('pastes/show_paste', identifier=paste.identifier), 
                        parent_url_for=url_for('pastes/show_paste', identifier=paste.parent.identifier),
                        compare_url_for=url_for('pastes/compare_paste', new_id=paste.identifier, old_id=paste.parent.identifier) %}
              on {{ date }} someone replied to your paste 
              <a href="{{ parent_url_for }}">#{{ parent }}</a>,
              in paste <a href="{{ paste_url_for }}">#{{ paste }}</a>. Click here to
              <a href="{{ compare_url_for }}">compare those two pastes</a>.{% endtrans %}
            {% endfor %}
            <p><a href="javascript:LodgeIt.hideNotification()">{% trans %}hide this notification{% endtrans %}</a></p>
        {% elif request.first_visit %}
          <div class="notification">
            <h3>{% trans %}Welcome On LodgeIt{% endtrans %}</h3>
            <p>{%- trans url_for=url_for('static/about') -%}
              Welcome to the LodgeIt pastebin. In order to use the notification feature
              a 31 day cookie with an unique ID was created for you. The lodgeit database
              does not store any information about you, it's just used for an advanced
              pastebin experience :-). Read more on the <a href="{{ url_for }}#privacy">about
              lodgeit</a> page. Have fun :-){%- endtrans -%}
            <p><a href="javascript:LodgeIt.hideNotification()">{% trans %}hide this notification{% endtrans %}</a></p>
        {% endif -%}
        {% block body %}{% endblock -%}
        <div class="footer"></div>