WordPress.org

Ready to get started?Download WordPress

Forums

[Plugin Simple Tags] st_the_tags outside the loop, how to ? (7 posts)

  1. neosting
    Member
    Posted 6 years ago #

    I am using thie template tag in the sidebar, so outside the loop. I call st_the_tags(); and it displayes no tag for this post. Outside the loop, i have to add 'post_id='

    How can i just show the current tags of the post(only show in the single.php page) ? I have tried 'post_id=current' and some others but nothing.

    Can you help me please ?

  2. Kafkaesqui

    Posted 6 years ago #

    Try this:

    <?php
    if( is_single() ) {
    	global $post;
    	st_the_tags();
    }
    ?>
  3. ohmz
    Member
    Posted 6 years ago #

    I have tried Kafkaesqui's recommendation above and it does not work.

    All I want to do is list the tags for the currently displaying post in the sidebar.

    Any and all feedback would be much appreciated. Thanks :)

  4. Rok
    Member
    Posted 6 years ago #

    Kaf can you advice "how to display "Technorati tags" & "Technorati Cloud" using Simple Tags plugin. I've tried a lot, but couldn't make it working. I've also written, about 5 times here on the fourm, and almost 10 times on the plugin author's comments and contact, but to no avail.

  5. Kafkaesqui

    Posted 6 years ago #

    ohmz, you could try:

    <?php
    if( is_single() ) {
    	global $post;
    	the_tags('<li><h2>Tags</h2><ul><li>','</li><li>','</li></ul></li>');
    }
    ?>

    Which I personally have set up and seen work in a site's sidebar. But this uses WP's built-in the_tags(). Not sure if that's an issue for you.

    Rok, I'm sorry but I don't use Simple Tags.

  6. ohmz
    Member
    Posted 6 years ago #

    How would I output those as a concurrently comma seperated list of tags?

  7. ohmz
    Member
    Posted 6 years ago #

    Sorry, silly question.
    What I meant was, how do I output the comma seperated list of plain text Tags in the sidebar, without any hyperlinks, stripping away any additions?

    Thanks for the patience :)

Topic Closed

This topic has been closed to new replies.

About this Topic