All we have left to do now, is re-compile the server with our new
module and set it up to use the header and footer module.
In this case, adding the filter to the filter chain is best done in the config
file with the AddOutputFilter directive which is defined by the core. Edit your
config file and find the Directory stanza for the directory you wish to add a
header or footer to. The AddOutputFilter directive takes the name of the filter
to add as its argument. In this case it is HEADERFOOTER. As long as we are here,
let’s also add two lines to add a header and footer file to the files in this
directory. Be careful when adding a header and footer to a page. If you add a
header file to a whole directory, and the header file is in that directory, then
your server will recursively send the header file forever. In the configuration
below, we are only adding the header and footer for the index page.