Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UPDATE #67: Add second footer widget section #69

Merged
merged 2 commits into from
Mar 20, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@ SMNTCS Retro bundles the following third-party resources:

== Changelog ==

=== 1.4 (2020.03.20) ===
* [Add second footer widget section](https://github.com/nielslange/smntcs-retro/issues/67)

=== 1.3 (2020.03.15) ===
* [Add 404 page](https://github.com/nielslange/smntcs-retro/issues/63)
* [Add menu level limitation to README.txt](https://github.com/nielslange/smntcs-retro/issues/57)
Expand Down
12 changes: 11 additions & 1 deletion footer.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,17 @@

<div id="footer-widget-wrapper">

<?php dynamic_sidebar( 'footer-sidebar' ); ?>
<div id="footer-widget-wrapper-left">

<?php dynamic_sidebar( 'footer-sidebar-left' ); ?>

</div><!-- #footer-widget-wrapper-left -->

<div id="footer-widget-wrapper-left">

<?php dynamic_sidebar( 'footer-sidebar-right' ); ?>

</div><!-- #footer-widget-wrapper-left -->

</div><!-- #footer-widget-wrapper -->

Expand Down
18 changes: 15 additions & 3 deletions functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -144,9 +144,21 @@ function smntcs_retro_sidebars() {

register_sidebar(
array(
'id' => 'footer-sidebar',
'name' => __( 'Footer Sidebar', 'smntcs-retro' ),
'description' => __( 'Add widgets to the footer sidebar.', 'smntcs-retro' ),
'id' => 'footer-sidebar-left',
'name' => __( 'Footer Sidebar Left', 'smntcs-retro' ),
'description' => __( 'Add widgets to the footer sidebar left.', 'smntcs-retro' ),
'before_widget' => '<div id="%1$s" class="widget %2$s">',
'after_widget' => '</div>',
'before_title' => '<h3 class="widget-title">',
'after_title' => '</h3>',
)
);

register_sidebar(
array(
'id' => 'footer-sidebar-right',
'name' => __( 'Footer Sidebar Right', 'smntcs-retro' ),
'description' => __( 'Add widgets to the footer sidebar right.', 'smntcs-retro' ),
'before_widget' => '<div id="%1$s" class="widget %2$s">',
'after_widget' => '</div>',
'before_title' => '<h3 class="widget-title">',
Expand Down
13 changes: 13 additions & 0 deletions style.css
Original file line number Diff line number Diff line change
Expand Up @@ -383,6 +383,19 @@ article p:first-of-type {
margin-bottom: 1em;
}

@media screen and (min-width: 580px) {

#footer-widget-wrapper {
display: flex;
}

#footer-widget-wrapper-left,
#footer-widget-wrapper-right {
padding-right: 2em;
}
}

#footer-credits-wrapper {
margin-bottom: 1em;
}