Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Possible Duplicate:
How should one implement add_settings_error on custom menu pages?

The Settings API offers all sorts of labour saving features and future proof code. I find it really odd that it's not designed to work with plugins using custom admin menus. Is there any reason for this? Is the situation likely to change in future?

share|improve this question
    
You might want to clarify what do you mean by "custom menus". –  Rarst Jul 21 '11 at 21:52
    
Custom admin menus? –  jnthnclrk Jul 21 '11 at 21:54
add comment

marked as duplicate by Chip Bennett, Rarst Jul 22 '11 at 13:11

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

1 Answer

The Settings API works just fine on any Admin page; it doesn't care where it is, as long as you tie the settings form to the registered setting, and provide a valid callback function.

share|improve this answer
    
It does? Damn, I'm doing something wrong then. wordpress.stackexchange.com/questions/23701/… –  jnthnclrk Jul 21 '11 at 22:31
    
can you explain how to tie the settings form to the registered setting? –  jnthnclrk Jul 22 '11 at 11:10
    
Simple: match the first argument in register_setting() to the argument passed to do_settings_fields() and to do_settings_sections(). –  Chip Bennett Jul 22 '11 at 12:31
    
Oops; make that settings_fields(). –  Chip Bennett Jul 22 '11 at 12:40
    
Unfortunately, that seems to break the add_settings_error functionality. –  jnthnclrk Jul 22 '11 at 12:43
show 2 more comments

Not the answer you're looking for? Browse other questions tagged or ask your own question.