• https://www.matthewbaltrusitis.com

    I am trying to make the title “Portfolio” itself linked to https://matthewbaltrusitis.com/portfolio

    This is the code as it is now:

    <?php wp_list_categories('orderby=name&child_of=12&title_li=<a>Portfolio</a>'); ?>

    Hopefully I told you everything you guys/gals needed in order to help me.

    Thanks a bunch,
    Matthew

Viewing 5 replies - 1 through 5 (of 5 total)
  • <?php wp_list_categories('orderby=name&child_of=12&title_li=<a>Portfolio</a>'); ?>

    I don’t know it that could work but if you use <a> , there will have to be a link…
    like

    <a href="https://matthewbaltrusitis.com/category/portfolio">Portfolio</a>

    but seriously, I’ve never thought of putting a link as title_li … so I’m not sure that can work… try…

    The other thing…
    It’s not
    matthewbaltrusitis.com/categories/portfolio
    but
    https://www.matthewbaltrusitis.com/category/portfolio

    you can change what it says (category or categories or whatever in the settings under permalinks)

    Good luck
    Anja

    Thread Starter mbaltrusitis

    (@mbaltrusitis)

    The other thing…
    It’s not
    matthewbaltrusitis.com/categories/portfolio
    but
    https://www.matthewbaltrusitis.com/category/portfolio

    you can change what it says (category or categories or whatever in the settings under permalinks)

    Ugh duh, obviously. Don’t know what I made the plural.

    ——

    I tried your suggestion, didn’t work.

    Try:

    <a href="<?php bloginfo('url);?>/portfolio">Portfolio</a>
    <?php wp_list_categories('orderby=name&child_of=12&title_li='); ?>

    Though I did notice that Portfolio is already a link in your site’s top nav menu.

    Thread Starter mbaltrusitis

    (@mbaltrusitis)

    I was able to achieve this by using

    <?php wp_list_categories('orderby=name&title_li='); ?>

    Believe it or not, but now I have a “Blog” link showing up. I tried adding:

    <?php wp_list_categories('orderby=name&exclude=BLOG ID #&title_li='); ?>

    But that didn’t work.

    exclude=BLOG ID is what you wrote?

    You’ll have to find out what ID your Blog-Category has and exclude that. Or did you allready do that? I can’t see from what you wrote.

    To find out the ID go to the Menu – categories and hold your Mouse over the blog- category. Then you will see the ID in the statusbar at the bottom of the browser.

    exclude=5 (where 5 of course is your blog categories’ ID)

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Making CSS List Linkable’ is closed to new replies.