Enter the web server first time to customize ID, password and store up ?

Started by "kar...@yahoo.com [rabbit-semi]" October 23, 2017
Hi, could I consult another question ? how to enter the web server for the first time can be customize ID, password and store up?

sspec_addrule ("/", "Admin", admin, admin, SERVER_HTTP, SERVER_AUTH_BASIC, NULL);
sspec_addxmemfile ("Title.gif", Title, SERVER_HTTP);
sspec_addxmemfile ("chipbkgrnd.gif", chipbkgrnd, SERVER_HTTP);
userid = sauth_adduser ("admin", "admin", SERVER_HTTP); // Login to Web server ID and Password
sauth_setusermask (userid, admin, NULL);

1. The first boot, web page with ID, password input field and SAVE button.
2. If the user only enter ID: admin, password: admin and press the OK button to enter the web server.
3. The next time, web page is still exists ID, password input field and SAVE button.
4. If you enter ID: abcd, password: 1234 and press the SAVE button, press the OK button to enter the web server.
5. Enter the web page again, only exists ID, password input field with no SAVE button, need to enter the customized ID, password to enter the web server (at this time, ID: admin, password: admin is invalid, because it is now ID: abcd, password: 1234)
6. If forget the customized ID, password, just to power off the RCM device or press the RESET button to initialize the setting again.

Are there any reference examples?