• Resolved drabina

    (@drabina)


    I have static page that has text intro under which I would like to display list of categories. I was pointed to the “wp_list_categories” function that will give me what I need. My question is, can I use that directly on the page edit screen? When I type:

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

    I get just the code text on the final page. No categories. And yes, I am using HTML mode for the text editor.

    Thanks.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hi,

    You can add the code in the static page of wordpress and if you are receiving any error message then provide it…

    Thanks,

    Shane G.

    Thread Starter drabina

    (@drabina)

    I am not receiving any error messages. It is that the page prints my PHP code without actually parsing and executing it.

    Thread Starter drabina

    (@drabina)

    Figured it out. I needed plugin Exec-PHP.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Adding code to static page body’ is closed to new replies.