jimmymjb2 Posted October 31, 2009 Share Posted October 31, 2009 I’d like to set up a Wordpress (Wp) installation so that when users log into the Wordpress side, they won’t have to log in to AjaXplorer (Ajxp) as well. According to various discussions at the Ajxp forums I need to use their auth.remote plugin, by calling ‘glueCode.php’ located in their directory structure. The problem I am having though is that I don’t fully understand how to go about doing this. I have some Wp experience but I’ve only just begun working with Ajxp. This coupled with the fact that I’m just beginning to learn the basics of PHP (which makes it hard to understand exactly how the glueCode.php works), leaves me without a leg to stand on. I’ve posted over at the Ajxp forums and got a few tips, but to my surprise, they ultimately asked that I just write my own Wp plugin and if can do this without getting any errors, then just tell them how I did it so they could include it in the documentation. I think they assumed I knew a lot more about these things than I actually do. I’d love to make this plugin on my own, but I’ve never made a serious Wp plugin, don’t know a great deal about PHP (just been working with it for a few months) and don’t understand how authentication works within these two systems I’m trying to tie together. There was no help from the Wp forums. Here is the code I was given as an example for creating a Wp plugin for glueCode: <?php /* Plugin Name: Name Of The Plugin */ // [...] previous code function Authenticate($username, $password) { // Please copy the other post code login code here... include("/path/to/AJXP/glue/code/glueCode.php"); // and the other lines too } // Tell wordpress that your plugin hooked the authenticate action add_action('wp_authenticate', Authenticate, 1); // You should hook the other action too, like creating user, and so on ?> I believe the “other post code” he is referring to above, is from this discussion regarding the passing of user info using the ‘glueCode.php’ I mentioned before: http://www.ajaxplorer.info/forum/comments.php?DiscussionID=466 I've tried a few things but can't really understand how to combine these to code examples to make a working plugin to pass user info back and forth. I’m way passed a deadline and now I am starting to really freak out. Plus, its now more of a personal mission to see this come to fruition. I thought this would be a relatively simple thing to do, but the documentation just wasn’t there from either side. So now I’m hoping that since the Wp and Ajxp experts weren’t interested in helping to make this work, that maybe the PHP experts would. I've built some highly customized Wp sites, have a basic knowledge of PHP and prefer to figure things out on my own. This time though it seems I need someone much more talented to direct me a bit more than usual. So any insight at all would be a great relief. Thanks Quote Link to comment https://forums.phpfreaks.com/topic/179700-using-wordpress-to-authenticate-users-in-ajaxplorer/ Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.