Viewing 9 replies - 1 through 9 (of 9 total)
  • Do not edit the Twenty Thirteen theme. It is the current default WordPress theme and having access to an original, unedited, copy of the theme is vital in many situations. First create a child theme for your changes. Or install a custom CSS plugin.

    Thread Starter spongevan

    (@spongevan)

    Thank you for your response, esmi.
    I already created a child theme.
    I copied the lines from functions.php which are related to the tags and pasted them on my child theme.

    $tag_list = get_the_tag_list( '', __( ', ', 'twentythirteen' ) );
    	if ( $tag_list ) {
    		echo '<span class="tags-links">' . $tag_list . '</span>';
    	}

    Then I tried to remove the commas and save it but it didn’t work.

    This is what my functions.php looks like before pasting the tags code.

    <?php
    //empty function.php
    function ws_credits () {echo '2013 © spongevan';}
    add_action('twentythirteen_credits', 'ws_credits');
    ?>

    What am I doing wrong?

    You have to create a new custom version of the relevant parent function within your child theme’s functions.php file. You can’t just drop in a few lines.

    Thread Starter spongevan

    (@spongevan)

    Ok, thank you for replying.
    How can I create that specific custom version? I’m new at php, sorry.

    Which function in the parent theme are you trying to change?

    Thread Starter spongevan

    (@spongevan)

    I think it’s this one:

    function twentythirteen_entry_meta() {

    Copy the entire function (lines 322 – 349) into your child theme. Then you can start customising the child’s version.

    Thread Starter spongevan

    (@spongevan)

    It worked! Commas are removed.
    Thank you very much for your help!

    No problem. You should now be able to customise almost any part of the theme to your heart’s content. 🙂

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Remove commas between tags’ is closed to new replies.