HTTP Commander AJS 1.5
Manual |
![]() ![]() |
Integration with Content Management Systems
Http Commander can be configured to use an account database of a CMS for authentication. That means that you will be able to use your account in a CMS to log into the Http Commander. Once logged into a CMS you'll be automatically authenticated in the Http Commander, provided that you've opened it through a special link in the CMS.
How it worksWhen you enter your user name and password into Http Commander login form, Http Commander sends an Http request with your name and password (or password hash) to an account-check page in the CMS. The CMS verifies the data and replies with either "yes" or "no". Http Commander reads the responce and authenticates you if the response is positive.
If you are logged into CMS, there is a link to Http Commander with embedded information about your account. The link includes your user name and password hash. When you follow this link, Http Commander receives your account information. Http Commander sends an Http request back to the CMS to verify data. If verification succeeds, you are logged into Http commander under the account you have in the CMS.
Http Commander can be integrated with the following CMSs: Drupal, Joomla, WordPress.
In order to integrate Http Commander with a CMS you need to 1) configure Http Commander to use a CMS for authentication; 2) configure the CMS to provide a link to Http Commander and verify account information.
Configuring Http CommanderTo use an account database of a CMS for authentication, you need to edit the Default.aspx and \App_Code\ExternalCMSIntegration.cs files in the Http Commander root directory.
Uncomment {CMS name}URL constant and assign a correct URL.
const string {CMS name}URL = "http://win2003-mws/{CMS name}/account-check.php";
In the Page_Load function uncomments the "automatic logon from CMS" block:
// automatic logon from CMS if (Request.QueryString["username"] != null && Request.QueryString["passwordhash"] != null) { string userName = Request.QueryString["username"].ToString(); string passwordHash = Request.QueryString["passwordhash"].ToString(); //if (ExternalCMSIntegration.ValidateUserPasswordHashDrupal(userName, passwordHash)) //if (ExternalCMSIntegration.ValidateUserPasswordHashJoomla(userName, passwordHash)) //if (ExternalCMSIntegration.ValidateUserPasswordHashWordPress(userName, passwordHash)) { FormsAuthentication.SetAuthCookie(userName, false); isAuthenticated = true; } }
In the btnLogin_Click handler, comment the ValidateUser call:
bool validated = Utils.AccountsManager.ValidateUser(txtUserName.Text, txtPassword.Text);
and uncomment:
bool validated = ExternalCMSIntegration.ValidateUserPassword{CMS name}(txtUserName.Text, txtPassword.Text);
Configuring Drupal
Now you'll be able to see the link to Http Commander on every page having that sidebar.
ScreenshotConfiguring Joomla
Now you'll be able to see the link to Http Commander on the left side of the page.
ScreenshotConfiguring WordPress
Now you'll be able to see the link to Http Commander.
Screenshot