If a user tries to edit content without having a valid ticket, they are notified that they need to log in. This notice is presented via a dialog, which is customizable with APIs in the
Client Application in two ways: the labels within the dialog and the action it performs when submitted.
You can change the title text, message text, submit button text, and cancel button text within the dialog. By default, the dialog title says "Please Login," the message says "You must be logged in to use this feature," the submit button says "Login," and the cancel button says "Cancel."
To customize your
login dialog labels, use the
Client Application's
WPCAPI.setLoginDialogProperties function.
As an example of where a user will see this
login dialog, they may click on the "EasyEdit" button without having previously logged in to your site. The following diagram illustrates this:
Take Them To Your Login
Notice in the example above, the dialog attempts to take the user to your site's login page when they click the Login button. By default, that action does nothing; you must tell it what action to perform by
overriding the
WPCAPI.processLogin function.
Next Step 7: Build Your Own Navigation