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.
The footer structure is not semantically structured. The only thing setting apart the footer sections are mock "headers" colored black instead of blue (see attached). These sections' top links should actually be structured as h2's (or h3's). This would make it more accessible to people with color-blindness and screen readers.
Comment | File | Size | Author |
---|---|---|---|
#12 | adding-structure-to-header-2121337.patch | 1.61 KB | mgifford |
footer-structure.jpg | 92.86 KB | Geijutsuka |
Comments
Comment #1
mgiffordAgreed. So rather than:
So it should be more like:
So each of the groups of lists in the footer would have a heading.
Comment #2
Geijutsuka CreditAttribution: Geijutsuka commentedI'm not privy to how the footer menu is currently generated, but the new structure can be implemented nicely with the menu block module, though the h3's would then be h2's.
Comment #3
zeta ζ CreditAttribution: zeta ζ commentedHas been confirmed …
Comment #4
eliza411 CreditAttribution: eliza411 commentedTagging.
Comment #5
mgiffordH2's would be fine.
Comment #6
tvn CreditAttribution: tvn commentedComment #7
mgiffordWhat's needed to fix this?
Comment #8
drummThis is actually set in drupalorg_crosssite.module, after the
// Build the footer navigation
comment.See http://drupal.org/node/1018084 for dev sites to try out changes.
Comment #9
mgiffordI put in a request here https://drupal.org/node/2170269
Not sure when I'll get to it, but always good to start the process.
Comment #10
mgiffordSo just to confirm what's there now. In modules/drupalorg_crosssite/drupalorg_crosssite.module in the drupalorg_crosssite_preprocess_page() function the footer is defined as an array:
$vars['page']['footer']
Which is then spit out in the bluecheese theme themes/bluecheese/tpl/page.tpl.php:
<?php print render($page['footer']); ?>
I am a bit unsure though as to where the array is processed... This would need to be broken up though so that we aren't just styling the first element in the list to look like a heading, but that it is actually a proper HTML heading.
Thoughts on approaches to break this down?
Comment #11
drummThat is all accurate. The render array doesn't necessarily need to be broken up, but rearranged. The call to
render()
inpage.tpl.php
is the processing, that part should stay untouched.I don't know the best way to format the array to add in headings. Since this is site-specific code, we aren't afraid of being hacky and putting markup in
#prefix
and#suffix
.Comment #12
mgiffordI don't know that I got the headings correct. I wasn't sure how these items were organized so made it up.
Comment #13
Geijutsuka CreditAttribution: Geijutsuka commentedcurrent heading:
Drupal News
current heading:
Community
current heading:
Get Started
current heading:
Download & Extend
current heading:
About
Comment #14
Geijutsuka CreditAttribution: Geijutsuka commentedDidn't know if I should change the code or not... just commented on prefix lines. Not sure if that was the correct way to review the patch. I still don't really have contributing etiquette down.
Comment #15
mgiffordThis is a totally fine way to provide feedback. Great etiquette.
I didn't change the links, simply the headings that are used to organize them.
In the present footers, the headers are actually their own links which roughly are associated with categories of links in the footer.
I could have simply replaced the link and made it a heading, but that didn't seem right either.
Comment #16
mgiffordIt's been about a month & a half since I posted a patch on this.
@Geijutsuka's comments were useful clarifications about the patch, but I think it's still good.
I don't think it's done right now, and these changes should be an improvement.
Comment #18
drummLooks good, committed & deploying.
Comment #19
mgiffordExcellent... Thanks @drumm.