Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I'm having issues with the layout of the theme. Here's an image highlight two problems:
1) the Branding block is displayed even though there is no content in that block
2) the edges of the Header block is overlapping with the blocks below it
Here is a screencap of the block structure for those:
How can these be resolved?
Comment | File | Size | Author |
---|---|---|---|
#11 | Screen Shot 2014-02-05 at 6.51.28 AM.png | 58.82 KB | kreynen |
#11 | Screen Shot 2014-02-05 at 6.44.47 AM.png | 72.95 KB | kreynen |
#4 | amherst02.png | 855.01 KB | jdcreativity |
#2 | Amherst01.png | 17.11 KB | jdcreativity |
AmherstMedia CMTheme problems 2 (blocks).png | 17.11 KB | bagelche |
Comments
Comment #1
jdcreativity CreditAttribution: jdcreativity commentedComment #2
jdcreativity CreditAttribution: jdcreativity commentedComment #3
jdcreativity CreditAttribution: jdcreativity commentedComment #4
jdcreativity CreditAttribution: jdcreativity commentedComment #5
bagelche CreditAttribution: bagelche commentedComment #6
jdcreativity CreditAttribution: jdcreativity commentedComment #7
jdcreativity CreditAttribution: jdcreativity commentedComment #8
bagelche CreditAttribution: bagelche commentedComment #9
bagelche CreditAttribution: bagelche commentedComment #10
bagelche CreditAttribution: bagelche commentedgadzooks! round-and-round trying to get the images to show up.
Comment #11
kreynen CreditAttribution: kreynen commentedFixing this isn't as easy as removing the branding div if there is no content. Wrapping the div in an if ($page['branding']) like this...
works for individual nodes, but not the frontpage...
Comment #12
westis CreditAttribution: westis commentedThis is related to the cm_slideshow CSS. On okv.se the branding block shows up in the HTML, but overridden with height: auto. But the red border, for example, is from the branding div.
I think this partly depends on the order of the blocks. channelaustin.org, for example, has another block order, but apparently an older version of cm_slideshow without the CSS that is causing errors on amherstmedia.org...
In case we want the default site, when installing the easy starterkit, to look like okv.se, some of the CSS from the OKV sub-theme to cm_theme_zen at okv.se should probably be transferred to cm_theme_zen instead. I paste that CSS here for now:
As said, some of these issues are related to how the blocks are being used. Originally I worked on cm_theme_zen for channelaustin.org and later adjusted some custom parts on okv.se. I'll make a separate post about this.
Comment #13
kreynen CreditAttribution: kreynen commentedI think we should fix this in a similar way to #2054019: Remove drop shadow on specific images. using drupal_add_css to dynamically add the CSS that removes the display of this region is it doesn't contain any content.
Comment #15
westis CreditAttribution: westis commentedFixes for this:
http://cgit.drupalcode.org/cm_theme/commit/?id=a1bcc4f5fd7d7c3adbc7f2b6e... (removing branding-spacer div and branding-spacer CSS, which means there's no div that adds that extra 6em)
http://cgit.drupalcode.org/cm_theme/commit/?id=48636fe726b0c021de9db059b... (adding bottom-border to header instead of branding div, so that it shows also on other pages than front)
http://cgit.drupalcode.org/cm_slideshow/commit/?id=61b16ab913699a772ae2c... (removed the negative top margin of cm_slideshow)
With these commits I consider this issue fixed, but please test.
Btw, I have since learnt how to refer commits to issues and the one who started the issue...
Comment #17
avguy CreditAttribution: avguy commentedIn https://www.drupal.org/node/2188071#comment-9376005 the fix was committed to version 7.x-3.x. That version was not added to the page as a release. Was that a mistake or are we supposed to use the 3.x version now for testing?