I've created a custom menu page with some fields. I want to store these settings to use elsewhere.
The form with the fields should save and POST data using action="options.php"
but every time I hit save on the form it sends me back to the settings page, and does not save the data.
I'm registering the settings in my functions.php
function register_settings() {
register_setting('settings-group','phonenumber');
register_setting('settings-group','primaryemail');
register_setting('settings-group','secondemail');
}
This is the form action
<form method="post" action="options.php">
Here is the full code which is in functions.php http://pastebin.com/zVhSLZ9d