Custom Wordpress 3.5.2 plugin “You do not have sufficient permissions to access this page.”

前端 未结 2 1903
星月不相逢
星月不相逢 2021-01-13 15:47

I have been trying to integrate a custom Wordpress plugin called custom_rss into Wordpress by following http://net.tutsplus.com/tutorials/wordpress/creati

2条回答
  •  爱一瞬间的悲伤
    2021-01-13 15:57

    So there is a solution!

    If you read the comments below the tutorial you will find a comment by a Robert character which states:

    Great article. 2 things: 1. The following code produces an error in Admin panel, that makes the page inaccessible:

    add_options_page("OSCommerce Product Display", "OSCommerce Product Display", 1, "OSCommerce Product Display", "oscimp_admin");
    

    ERROR: "You do not have sufficient permissions to access this page."

    To remove this error, modify the above code to:

    add_options_page("OSCommerce Product Display", "OSCommerce Product Display", 1, "OSCommerce_Product_Display", "oscimp_admin");
    

    That change will help you display the page correctly when the link "OSCommerce Product Display" is clicked under the "Settings" menu option. Hope this helps anyone who experienced a problem with the code.

    1. "The first parameter of this function is the option name which will be sued later to uniquely identify this option and its value." It should have been "used" but incorrectly spelled as "sued". Not a big deal, but just wanted to let you know.

提交回复
热议问题