Dynamic Footer Revisited

The original Digital raindrops dynamic footer for the Artisteer themes was a great success, we have revisited the Dynamic Footer functions and streamlined the process, the new footer can be activated with modification to just two files and a fewer lines.

The dynamic footer will take up to four widgets and auto size the width in a percentage of the theme sheet width, the styling of the widgets is taken from the sidebars, so if you have a background color in your sidebars then you need to add this to the widget styling, lets make a start on installing the footer.

THEME

You can view a theme with the footers here: 

Image-3

To start you will need the files, you can download just the footer files to follow the tutorial  [download id="9"] and or the whole theme with both the footer and template examples [download id="10"] .

Functions File

Open your themes functions.php and add these lines on ‘line two’ after <?php.

/* Start CMS-Footer functions */
if (file_exists(TEMPLATEPATH. '/cms-footer-functions.php')) include_once(TEMPLATEPATH. '/cms-footer-functions.php');

Move to the end of the file and add these lines as the ‘last two’ and save the file


/* add the Footer widgets */
cms_make_footers();

Footer File

Open the themes footer.php, add these lines at ‘line one’ before any of the Artisteer code and save the file.


<!-- Start CMS-Footer functions -->
<?php if (file_exists(TEMPLATEPATH. '/cms-footer.php')) include_once(TEMPLATEPATH. '/cms-footer.php'); ?>

Styling

The css style for the footer is in the file cms-footer.css, you can add any extra padding or styling in this file, maybe to set the background color to the same as your sidebars, for a fixed height of 250px you would add height: 250px; to the block below.


.cms-footer
{
    background-color: transparent;
    position: relative;
    padding: 0;
    float: left;
    overflow: hidden;
    margin-top:7px;
    width: 100%;
}

Footer Widgets

Upload the files to your WordPress environment activate the theme and you will see the addition of widgets ‘Footer 1′ to ‘Footer 4′, populate these from the first, if you only wanted two or three then only add widgets to the ones you want, the function looks at how may footer sidebars are active and adjusts the width as required, it will also switch the number of footer sections to show as well.

Notice

Code disclaimer information
This document contains programming examples therefore, www.DigitalRaindrops.net grants you a nonexclusive copyright license to use all programming code examples from which you can generate similar function tailored to your own specific needs.

All sample code is provided by www.DigitalRaindrops.net for learning illustrative purposes only.

These examples have not been thoroughly tested under all conditions. www.DigitalRaindrops.net, therefore, cannot guarantee or imply reliability, serviceability, or function of these examples.

All programs contained herein are provided to you “AS IS” without any warranties of any kind. The implied warranties of non-infringement, merchantability and fitness for a particular purpose are expressly disclaimed.

Membership

We hope you will benefit from our tutorials Membership to this website is not required, however the downloading of any themes or files is restricted to site supporters.

You can register for a 10 year ‘Free Account’ from the members page which will give you access to the source files and free themes, as we introduce premium themes and content these will only be downloadable with a subscription, any revenue from subscriptions is used to support the site costs.

this website is a tool to support and promote WordPress and Artisteer, please support, share and give credit for any benefits you gain from the tutorials on this website.

4 thoughts on “Dynamic Footer Revisited

  1. I am looking to edit my dynamic footers on a previous website, but I used the original tutorial you had here. Do you think you could post a link to the original or send me the files? I plan to just delete them and use your new tutorial, but I don't remember exactly what I added.

  2. in my artisteer generated theme there are 3 styling sheet. 1.style.css, 2.style.ie6.css and 3.style.ie7.css. Can you tell me which one is my footer scc file.

  3. Thank you for the tutorial! I’ve noticed that when I only populate 2 of the widgets they do not correctly show up (% width wise) as compared to Firefox or Chrome. Any thoughts?

Leave a Reply

Connections

Connect with Us
Follow Digital Mobile on Twitter Join Digital Mobile on Facebook
Share

Meet the Author

Articles by Digital Raindrops
Digital Raindrops admin is the author of the posts and this theme, WordPress development is a hobby taking more time than it really should.
Read More

Related Posts