template_redirect: How do I get the permalink? (2 posts)

  1. saphod
    Posted 7 years ago #

    I am using the Kimili Flashembed plugin to integrate some flash movies. I want to display a message when the feed is viewed that, if the feed doesn't show up, you should visit the original post (which is linked to).

    Showing the message is not a problem using "if(is_feed())", but I cannot retrieve the permalink with "get_permalink()".

    I suppose this is because of the action hook that is used, "template_redirect". I guess the functions mentioned are not yet initiated at that point.

    Does anyone know how I can retrieve the permalink within the template_redirect hook so that I can link to the post?

    Thanks in advance!

  2. saphod
    Posted 7 years ago #

    Ooops... I have just seen that I posted a similar problem already (7 months ago, that is), but it is still kind of different:


    I need that permalink -! :'-(

    Or at least a way to put a link to the post, so that "... the original post ..." actually leads to the original post.

    Help will be deeply appreciated.

Topic Closed

This topic has been closed to new replies.

About this Topic