Forums

[resolved] Retireve author id as a number. (2 posts)

  1. anabelle
    Member
    Posted 5 years ago #

    Is ther any variable i can use to retrieve the author id of a certain post inside the loop?

    i've tried $authid but it doesn't seam to work, i've also tried the_author_ID() but it writes down the number and i need to use it as a parameter inside a php function.

  2. anabelle
    Member
    Posted 5 years ago #

    I solved it using:

    <?
    global $theauthorID;
    $theauthorID = get_the_author_ID();
    ?>

    And then calling $theauthorID inside the function

    ;)

Topic Closed

This topic has been closed to new replies.

About this Topic