summaryrefslogtreecommitdiff
path: root/web/views/test/potlatch/categories.erb
blob: 97725a3a23e7618682d34dfe42bb7f9aac6d2831 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
<h1><img src="/img/sources/potlatch.32.png" alt="" title="Potlatch"/> Potlatch</h1>

<table class="drilldown"><tr>
    <th><h2>&#x278a; Categories</h2></th>
    <th></th>
    <th><h2>&#x278b; Features</h2></th>
    <th></th>
    <th><h2>&#x278c; Feature</h2></th>
</tr><tr>
    <td class="content" id="categories">
        <% @categories.each do |row| %>
            <div>&nbsp;&nbsp;<a href="/test/potlatch/categories#<%= escape row['id'] %>"><%= row['name'] %></a></div>
        <% end %>
    </div>
    <td class="arrow">&#x2771;</td>
    <td class="content" id="features"></td>
    <td class="arrow">&#x2771;</td>
    <td class="content" id="feature"></td>
</tr></table>

<script type="text/javascript">

jQuery('#categories a').bind('click', function() {
    jQuery('#categories div').removeClass('current');
    jQuery(this).parent().addClass('current');
    jQuery('#feature').html('');
    jQuery.ajax({
        url: this.href.replace(/#/, '/'),
        success: function(html) {
            jQuery('#features').html(html);
        }
    });
    return false;
});

</script>