WordPress.org

Support

Support » Themes and Templates » [Resolved] Twenty Twelve footer

[Resolved] Twenty Twelve footer

  • Can I put a table in the footer of the twenty twelve theme using html? Basically, instead of having image widgets in the side bar, I would like to insert the images in a table then add it to the footer.

Viewing 15 replies - 1 through 15 (of 38 total)
  • Yes you can. It’s pretty easy (well, compared to some other things anyway).

    Firstly, start off by creating a child theme so that your changes won’t get over-written in the next theme update.

    Secondly, copy the footer.php file to your child theme and edit away! That file is probably the best starting point because it’s pretty small so there’s not a lot to take in.

    Is it necessary to create a child theme, can I not just plop the table in the footer, like so:

    <?php
    /**
     * The template for displaying the footer.
     *
     * Contains footer content and the closing of the
     * #main and #page div elements.
     *
     * @package WordPress
     * @subpackage Twenty_Twelve
     * @since Twenty Twelve 1.0
     */
    ?>
    	</div><!-- #main .wrapper -->
    	<table>
    	<tr><td>image</td>
    </tr>
    	</table>
    	<footer id="colophon" role="contentinfo">
    		<div class="site-info">
    			<?php do_action( 'twentytwelve_credits' ); ?>
    			<a>" title="<?php esc_attr_e( 'Semantic Personal Publishing Platform', 'twentytwelve' ); ?>"><?php printf( __( 'Proudly powered by %s', 'twentytwelve' ), 'WordPress' ); ?></a> <strong>
    		</div><!-- .site-info -->
    	</footer><!-- #colophon -->
    </div><!-- #page -->
    
    <?php wp_footer(); ?>
    </body>
    </html>

    [Please post code & markup between backticks or use the code button. Your posted code has now been permanently damaged by the forum’s parser.]

    But if not, I create a child theme (throw in all the code I have above), save it as footer_table.css,

    esmi

    @esmi

    Forum Moderator

    No. Do not edit the Twenty Twelve theme. It is the default WordPress theme and having access to an unedited version of the theme is vital when dealing with a range of site issues. First create a child theme for your changes.

    Sorry for posting the same thing twice (I accidentally hit tab). Plus, I save the file as style.css and place it in the twentytwelve child.

    esmi

    @esmi

    Forum Moderator

    No – code does not belong in a style.css file. You need to save this file as footer.php in your child theme.

    I saved the new footer.php file, created the twentytwelve-child directory. After I uploaded the footer.php file to the twentytwelve-child directory, I received the error “stylesheet missing”. I then copied and pasted the style.css file into the twentytwelve-child directory, then received the message “template files missing”.

    Should I have included “@import url(“../twentytwelve/style.css”); into the footer.php file?

    WPyogi

    @wpyogi

    Forum Moderator

    Sounds like your child theme may not be set up or working correctly. Please post a link to your site.

    No, @import does not go in any file except style.css.

    WPyogi

    @wpyogi

    Forum Moderator

    You don’t have a child theme active on that site – did you activate it after creating it? (Just like switching to any other new theme.)

    This is the message I receive:

    Broken Themes

    The following themes are installed but incomplete. Themes must have a stylesheet and a template.

    Name Description
    twentytwelve-child Stylesheet is missing.

    It will not let me activate it. I saved the footer.php in the twentytwelve-child directory, as per the info above. I did try copying and pasting the style.css into the twentytwelve-child directory but then received the message function template is missing.

    I’m unsure what other files to put in the twentytwelve-child directory.

    WPyogi

    @wpyogi

    Forum Moderator

    Start at the beginning. Remove any other files except the new style.css file – which should only have this at the top of it:

    /*
    Theme Name: Twentytwelve Child
    Description: Child theme for the twentytwelve theme
    Author: Your name here
    Template: twentytwelve
    */
    
    @import url("../twentytwelve/style.css");

    Is the file structure correct? The child theme should not be inside the parent theme. Do you see the child theme in your themes screen?

    What is the name on the child theme folder?

    The child theme is in the correct folder and I see it. Now, back to the original question, how do I put a plain html coded table in the footer.php?

    WPyogi

    @wpyogi

    Forum Moderator

    It’s not active on your site.

    I have activated the child theme.

Viewing 15 replies - 1 through 15 (of 38 total)
  • The topic ‘[Resolved] Twenty Twelve footer’ is closed to new replies.
Skip to toolbar