Switch to side-by-side view

--- a/Allura/allura/templates/repo/commit.html
+++ b/Allura/allura/templates/repo/commit.html
@@ -32,30 +32,32 @@
         <div class="inline-diff">
             <h6>
             {% if type in ('added', 'changed') %}
-                <a href="{{commit.url()}}tree{{h.really_unicode(file)}}">{{h.really_unicode(file)}}</a>
-                <a class="commit-diff-link" href="{{commit.url()}}tree{{h.really_unicode(file)}}?diff={{prev[0].object_id}}">Diff</a>
+                <a href="{{commit.url()}}tree/{{h.really_unicode(file)}}">{{h.really_unicode(file)}}</a>
+                {% if prev %}
+                    <a class="commit-diff-link" href="{{commit.url()}}tree/{{h.really_unicode(file)}}?diff={{prev[0]._id}}">Diff</a>
+                {% endif %}
             {% elif type == 'removed' %}
-                <a href="{{prev[0].url()}}tree{{h.really_unicode(file)}}">{{h.really_unicode(file)}}</a>
+                <a href="{{prev[0].url()}}tree/{{h.really_unicode(file)}}">{{h.really_unicode(file)}}</a>
             {% elif type == 'copied' %}
-                <a href="{{prev[0].url()}}tree{{h.really_unicode(file.old)}}">{{h.really_unicode(file.old)}}</a>
+                <a href="{{prev[0].url()}}tree/{{h.really_unicode(file.old)}}">{{h.really_unicode(file.old)}}</a>
                 to
-                <a href="{{commit.url()}}tree{{h.really_unicode(file.new)}}">{{h.really_unicode(file.new)}}</a>
+                <a href="{{commit.url()}}tree/{{h.really_unicode(file.new)}}">{{h.really_unicode(file.new)}}</a>
             {% endif %}
             </h6>
             <div id="diff-{{loop.index}}" class="inline-diff-body">
                 {% if type != 'removed' %}
-                <img src="{{g.forge_static('images/spinner.gif')}}" class="loading_icon" alt="Loading..."/>
+                    {% if prev %}
+                    <img src="{{g.forge_static('images/spinner.gif')}}" class="loading_icon" alt="Loading..."/>
+                    <script type="text/javascript">
+                        $(document).ready(function() {
+                            $('#diff-{{loop.index}}').load('{{commit.url()}}tree/{{h.really_unicode(file)}}?barediff={{prev[0]._id}}');
+                        });
+                    </script>
+                    {% endif %}
                 {% else %}
                 <span class="empty-diff">File was removed.</span>
                 {% endif %}
             </div>
         </div>
-    {% if type != 'removed' %}
-        <script type="text/javascript">
-            $(document).ready(function() {
-                $('#diff-{{loop.index}}').load('{{commit.url()}}tree{{h.really_unicode(file)}}?barediff={{prev[0].object_id}}');
-            });
-        </script>
-    {% endif %}
 {% endfor %}
 {% endblock %}