change this to a list group - other items
<p>Other item format is a bit average, list group should fix this. </p>
<p><img src="https://i.imgur.com/n9jxHZW.png" /></p>
<p>This uses the template:</p>
<p><code>core-list-item-simple.html </code></p>
<p>So we can change this a bit to the list group format. </p>
<p>Which is basically this layout</p>
<h4>HTML</h4>
<pre><code class="html hljs xml"><ul class="list-group"><br /> <li class="list-group-item">An item</li><br /> <li class="list-group-item">A second item</li><br /> <li class="list-group-item">A third item</li><br /> <li class="list-group-item">A fourth item</li><br /> <li class="list-group-item">And a fifth one</li><br /></ul></code></pre>
<p>as i want it to be links, need to use the same classes and links instead. </p>
<h4>HTML</h4>
<pre><code class="html hljs xml"><div class="list-group"><br /> <a href="#" class="list-group-item list-group-item-action active" aria-current="true"><br /> The current link item<br /> </a><br /> <a href="#" class="list-group-item list-group-item-action">A second link item</a><br /> <a href="#" class="list-group-item list-group-item-action">A third link item</a><br /> <a href="#" class="list-group-item list-group-item-action">A fourth link item</a><br /> <a href="#" class="list-group-item list-group-item-action disabled" tabindex="-1" aria-disabled="true">A disabled link item</a><br /></div></code></pre>
<p>Changed templates to use the list-group.html and list-group-item.html rather than the core templates. </p>
<h4>HTML - list-group-item.html</h4>
<pre><code class="html hljs xml"><a href="/view/[@classname]/[@uid]/[@titleuid]/" class="list-group-item list-group-item-action" title='[@title]'>[@title]</a<br /></code></pre>
<h4>HTML - list-group-card.html</h4>
<p>a list group inside a card to make it neater. </p>
<pre><code class="html hljs xml"><div class='card mb-3'><br /> <h5 class='card-header'>[@title]</h5><br /> <div class='card-body'><br /> <div class="list-group"><br /> [@content]<br /> </div><br /> </div><br /></div></code></pre>
<p>Updated quite easily once i found the function. </p>
<p>Now it looks something like this: </p>
<p><img src="https://i.imgur.com/DxpO7Rh.png" /></p>
<p>Which is quite a lot nicer than the simple links and also better for mobile as you can press anywhere on the element, and makes it a bit more like buttons. </p>
PHP
if($class->category > " ") {
$other_items_list_title = "Other Items in $class->category";
$other_items_list = $class->list_all(
$start = 0,
$max = 50,
$list_type = "category",
$template_file = "list-group-item.html",
$search_term = $class->category
);
$other_items_card_template = new template("list-group-card.html");
$other_items_card_template->set("title", $other_items_list_title);
$other_items_card_template->set("content", $other_items_list);
$page_content .= $other_items_card_template->output();
}