WordPress.org

Ready to get started?Download WordPress

Forums

Debug Errors from WP-includes (7 posts)

  1. cmunns
    Member
    Posted 3 years ago #

    Theme debug throws errors from wp-includes. How is this related to the theme files?

    e.g. Notice: has_cap was called with an argument that is deprecated since version 2.0! Usage of user levels by plugins and themes is deprecated. Use roles and capabilities instead. in /Library/WebServer/Documents/wordpress/wp-includes/functions.php on line 3321

    I deleted all plug-ins and searched inside of ALL my template files and still get this error and a few others that come from inside of wp-includes.

    Because of these errors the theme is not being accepted into the free theme directory.

  2. dogbot
    Member
    Posted 3 years ago #

    did you ever get an answer? I get this error too. I am using WP 3.0.1
    Thanks

  3. Luke McDonald
    Member
    Posted 3 years ago #

    I am getting the same thing. However, I get the notice to disappear when when I take my theme options menu call of my function.php file.

    add_action('admin_menu', "cs_debut_admin_init");

    Even if I take out the "cs_debut_admin_init" function completely, the notice is still thrown. Interesting....

  4. esmi
    Theme Diva & Forum Moderator
    Posted 3 years ago #

    Try ensuring that you're not using any deprecated tags or functions in your theme.

  5. Luke McDonald
    Member
    Posted 3 years ago #

    I found the solution on tumbledesign.com.

  6. Luke McDonald
    Member
    Posted 3 years ago #

    Just so the solution is here as well. It had to do with using a role identifier instead of a capability in the add_theme_page() function:

    Wrong: (the use of "8")
    add_theme_page( "Debut Options", "Theme Options", 8, 'cs_debut_admin_menu', 'cs_debut_admin');

    Correct: (i used "switch_themes")
    add_theme_page( "Debut Options", "Theme Options", 'switch_themes', 'cs_debut_admin_menu', 'cs_debut_admin');

  7. dudesl
    Member
    Posted 3 years ago #

    here a same problem whit a detailed solution. The font is the same: tumbledesign.com

    http://wordpress.org/support/topic/has_cap-was-called-with-an-argument-that-is-deprecated?replies=8#post-1775460

Topic Closed

This topic has been closed to new replies.

About this Topic