WordPress.org

Forums

wp_list_categories() php warning (3 posts)

  1. miniCarl
    Member
    Posted 2 years ago #

    When I use wp_list_categories() I get this PHP warning (one time for each category i have)

    Warning: mysql_real_escape_string() expects parameter 1 to be string, object given in /home/qs/public_html/wp-includes/wp-db.php on line 789

    After that, the categories are listed as normal.
    I have tried overwriting all the wordpress files on my server with a fresh set.

  2. Johnb81
    Member
    Posted 2 years ago #

    I think the code you are writing is incorrect and not WordPress. Mind sharing the code?

  3. miniCarl
    Member
    Posted 2 years ago #

    <ul class="category-list">
       <?php wp_list_categories('title_li='); ?>
    </ul>

    Worked before :/

Topic Closed

This topic has been closed to new replies.

About this Topic