Follow these steps to create a folder for your templates:
Create a new folder in
blocks\page_list\templates
callednews_2
.Copy the previously created
news.php
file into this directory and rename itview.php
.Create a new file called
view.css
with the following content:.ccm-page-list { border-bottom: 1px solid gray; padding-bottom: 20px; margin-bottom: 20px; } .ccm-page-list a { color: #262626; }
We created a folder instead of a single file for our template. While view.php
is mandatory, there are lots of optional files you can use. Within a template in the templates folder, the following are the files included by concrete5 in the header:
view.js
view.css
js/<anything>.js
css/<anything>.css
Whether you put the CSS rules in your theme or template using view.css
or the css
folder has to be decided for each situation. There's not a single correct answer. But think about whether you would like to reuse the template...