WordPress.org

Ready to get started?Download WordPress

Forums

How to customise wp_cloud tag and turn template into fluid design (4 posts)

  1. centsandsensibility
    Member
    Posted 3 years ago #

    Hi all,

    I'm sorry I'm quite new to word press (although I do have some experience in coding) and was after some advise as to how to make my wp tag cloud tag customisable. Currently it shows all my tags which makes it extremely long. Is there an easy way to limit it and if so what's the appropriate code, I have tried everything and nothing seems to work!

    http://www.vent2me.com.au/blogs

    On another note, is there way to make my template fluid width? it looks great on standard screens but on my netbook and other screens, my site doesn't look great at all. My theme is based on the twenty 10 template.

    Any tips would be much appreciated.

    Thanks again for your help and applogies if I have posted this in the wrong forum.

    Also - if you have any advice on how to make my site better and more userfriendly please let me know because I'm always happy to recieve tips from experts!

    Thanks again,

    Julia

  2. alchymyth
    The Sweeper & Moderator
    Posted 3 years ago #

    a:

    adding this into functions.php of your theme will allow you to set any parameter of the tag cloud:

    add_filter('widget_tag_cloud_args','set_number_tags');
    function set_number_tags($args) {
    $args = array('number'    => 20, 'largest'    => 25);
    return $args;
    }

    the parameter above are examples; full list in here:
    http://codex.wordpress.org/Function_Reference/wp_tag_cloud

    b:
    i haven't yet seen any workable conversion of twenty ten to fluid layout.

  3. centsandsensibility
    Member
    Posted 3 years ago #

    Hi alchymyth,

    Great, thank you so much for this. It works!

    Cheers,

    Julia

  4. joshuatuscan
    Member
    Posted 3 years ago #

    How would you modify this

    add_filter('widget_tag_cloud_args','set_number_tags');
    function set_number_tags($args) {
    $args = array('number'    => 20, 'largest'    => 25);
    return $args;
    }

    To exclude some tags if the tags were something like video, video_archive, et cetera?

Topic Closed

This topic has been closed to new replies.

About this Topic