Adding margin below breadcrumbs
Permalink
New to Concrete, and unsure where to go to modify the CSS for the breadcrumb trail to add 10px of margin below; or to modify the template somehow, to add in a blank line.
Or add an 'HTML block' and put a <br> in it.
I may end up doing either of those two things. I appreciate the advice. I've been scouring the server looking for anything related to the breadcrumb trails, to see if I could add something in to the code ... which is probably a bad idea anyway.
It just seems like a hack to me to not alter the individual block, but rather add more blocks to equate to the same functionality.
It just seems like a hack to me to not alter the individual block, but rather add more blocks to equate to the same functionality.
You could add a div to the breadcrumb.php and then style it from your css.
In your theme css add
<?php defined('C5_EXECUTE') or die(_("Access Denied.")); echo '<div class="bc">'; $navItems = $controller->getNavItems(); foreach ($navItems as $ni) { if (!$ni->isFirst) { echo '<span class="ccm-autonav-breadcrumb-sep"> ></span> '; } if ($ni->isCurrent) { echo $ni->name; } else { echo '<a href="' . $ni->url . '" target="' . $ni->target . '">' . $ni->name . '</a>'; } } echo '</div>';
In your theme css add
.bc{margin-bottom:10px}
This is what I'm looking for, and it looks really good, but I can't get it to work.
This is what I did. Went into concrete/blocks/autonav/templates and downloaded a copy of breadcrumb.php. Then went into concrete/themes/greek_yogurt and downloaded a copy of main.css.
In breadcrumb.php, I added in a second and last line, to make it look like the code sample you provided. Then in main.css I added your code to the bottom of the file. Then replaced the two original files, cleared the site cache and browser cache. Nothing happened, and I don't know PHP, so couldn't say why.
This is what I did. Went into concrete/blocks/autonav/templates and downloaded a copy of breadcrumb.php. Then went into concrete/themes/greek_yogurt and downloaded a copy of main.css.
In breadcrumb.php, I added in a second and last line, to make it look like the code sample you provided. Then in main.css I added your code to the bottom of the file. Then replaced the two original files, cleared the site cache and browser cache. Nothing happened, and I don't know PHP, so couldn't say why.
Are you calling from concrete root or updates?
Yeah, you see, I don't know. ... I've been using the idea of an HTML block with a break tag in it, and it seems to work just fine. ... Perhaps I will go back and take out my edits on those other two files.
Possibly a stack will work. I haven't used those yet, but those sound similar to what I'm talking about. One command that will do the job.
Thanks for all your help.
Possibly a stack will work. I haven't used those yet, but those sound similar to what I'm talking about. One command that will do the job.
Thanks for all your help.
If you want to do minimal css, another option is to use the basic breadcrumb template, then use 'design' for the block to add a bottom margin to the design.
If you are altering templates, then you should begin looking at overrides (in the docs and howtos).
If you are altering templates, then you should begin looking at overrides (in the docs and howtos).
http://www.concrete5.org/marketplace/addons/spacer/...
or
http://www.concrete5.org/marketplace/addons/spacer-margin/...