WordPress.org

Forums

[resolved] how to add 'random' text link to header? (4 posts)

  1. dinneenp
    Member
    Posted 6 years ago #

    I just want the word 'RANDOM' in my header as a link to a random page
    Currently I have managed to add p'revious' and 'next' in the header:

    '<?php previous_post('%', 'PREVIOUS ', 'no'); ?>
    <?php next_post('%',' NEXT', 'no'); ?> ''

    I've checked and this seems to be on the right track but I can't complete it:
    ?php
    $randomnumber = rand(1,3);
    ?
    Any help?Thanks,
    Patrick.

  2. dinneenp
    Member
    Posted 6 years ago #

    Sorry...my site is http://patrick.dinneen.com

  3. 11worth
    Member
    Posted 6 years ago #

    Is this plugin what you're looking for?

  4. dinneenp
    Member
    Posted 6 years ago #

    Thanks, I'll try that.
    But why should one need a plug-in for it, shouldn't it just be a bit of code?

Topic Closed

This topic has been closed to new replies.

About this Topic