charlener
Forum Replies Created
-
Forum: Plugins
In reply to: [Plugin: External DB authentication] Integration WordPress and MoodleHi Edson,
I think that this is something that is (as yet) unknown for me as to how to do it. I know moodle has external authentication settings, but, as other posters have shown here, we don’t know how to authenticate to an external wordpress database yet. Once someone figures that out, I think you could do what you want in moodle, too.
Hi outspaced,
Do you know what the SQL server equivalent query may be for setting UTF-8? It does affect import of fields, and I’d prefer this to work across all setups.
Or do you know if unicode fields were already importing correctly with SQL Server?
Hey,
you may want to check to make sure you’re filling in the configuration fields properly. The first username’s for accessing the database with the information, and the second username’s for matching a field in a table in the database for authenticating. Root’s a possible login for database access if you’re running your own setup, but doesn’t sound like a likely field for the username field in the table.
Forum: Plugins
In reply to: [Plugin: External DB authentication] Can’t login, stuck at configurations…Ok Takuya, I think this link may work. It’s not using the plugin but describes how to share common logins among multiple wordpress setups.
Forum: Plugins
In reply to: [Plugin: External DB authentication] plugin give empty login pageI think it’s a config problem most likely. I just went through checks with 2.8.6 and 2.9 and both of them are working fine.
I bet all the fields are correct, but possibly Drupal, like other systems, has a particular hashing system that is more involved that a basic sha1, md5, or variant thereof. This site seems to indicate that Drupal 7, at least, may be using phpass. You would have to use code based on that to hash the (initial plaintext) password a user enters and compare to what’s on the Drupal user database.
This is also what wordpress is supposed to be doing, but I’m having issues getting it to work across two wordpress installs per this post.
Forum: Fixing WordPress
In reply to: [Plugin: External DB authentication] How does this work?Hmm. What do you mean by integrated use? It lets you login with their credentials from the “old” SMF database, right? Is there more you want it to do?
Forum: Requests and Feedback
In reply to: [Plugin: External DB authentication] Problem with German umlautHi Thomas,
I added some MySQL things so that it works now – I tried it with umlauts and cyrillic text. Will post shortly.
Forum: Plugins
In reply to: [Plugin: External DB authentication] Can’t login, stuck at configurations…FYI I tried that while testing with 2.8, and it doesn’t work. I thought this may help: generate hashed pw but still didn’t give me any useful results. Sorry…maybe someone else can assist.
Forum: Plugins
In reply to: [Plugin: External DB authentication] Small bugHoodie – depends on what you mean by “integrating,” I think. Please give a bit more detail, as this plugin focuses on using another, existing database for logins.
Forum: Plugins
In reply to: [Plugin: External DB authentication] Small bugHi Keith – Thanks for the heads up re: that line to insert. I’ve added it in. The one caveat that would need to be mentioned, though, is that if you don’t have an account called “admin” in that external table that default admin account for wordpress won’t authenticate properly. That kind of makes sense, though, from making *all* usernames externally pulled rather than an exception here and there. Right?
Concerning your second point, could you give a bit more information? Are you using WPMU? And when do the defaults get blanked out, then? Just want to check to see if putting in default values makes sense in general for the released version, though I don’t *think* it quite does…
Forum: Plugins
In reply to: [Plugin: External DB authentication] Can’t login, stuck at configurations…From what I can tell, wordpress uses the Portable PHP password hashing framework (phpass). This can be found in wp-includes/class-phpass.php. You can look over it to see the steps to generate passwords if you want to replicate it in the custom hash code, but it looks complicated.
I think, from pluggable.php, since I don’t redefine this function, you can actually use
$password2 = wp_hash_password($password);
If you’re still looking for a solution, try this and let me/us know if it works.
Forum: Plugins
In reply to: [Plugin: External DB authentication] plugin give empty login pageHey, I’m finally getting around to making sure this works with 2.8+, so look for the next release version to work, hopefully tonight.
Alrighty,
Added into version 3.1. Give it a shot and let me know what you think.
I just noticed WP-MU got the 2.7 release – I’ll try the new plugin code with it too and see if it works for everyone…
Hmm. Are these role ids typically in some sort of numeric range, or only numeric? This doesn’t sound hard to add, though you’d still have to go that extra step of setting up in WP what local WP role will assign for new accounts.
Think it’s doable with more info on what typical data type is used for role ids.
Forum: Plugins
In reply to: saving options issue with 2.7Thanks to this blog post I figured it out.
Here’s the modified and working code:
<?php /* Plugin Name: Test Plugin URI: https://URI_Of_Page_Describing_Plugin_and_Updates Description: A brief description of the Plugin. Version: The Plugin's Version Number, e.g.: 1.0 Author: Name Of The Plugin Author Author URI: https://URI_Of_The_Plugin_Author */ /* Copyright YEAR PLUGIN_AUTHOR_NAME (email : PLUGIN AUTHOR EMAIL) This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ function my_plugin_activate() { add_option("test", "12345"); } function myplugin_admin_init(){ register_setting('test-options', 'test'); } function my_plugin_menu() { add_options_page('My Plugin Options', 'My Plugin', 8, __FILE__, 'my_plugin_options'); } function my_plugin_options() { register_setting('test-options', 'test'); ?> <div class="wrap"> <h2>Plugin name</h2> <form method="post" action="options.php"> <?php settings_fields('test-options'); ?> <table class="form-table"> <tr valign="top"> <th scope="row">New Option Name</th> <td><input type="text" name="test" value="<?php echo get_option('test'); ?>" /></td></tr> </table> <p class="submit"> <input type="submit" name="Submit" value="Save changes" /> </p> </form> </div> <?php } add_action('admin_menu', 'my_plugin_menu'); add_action( 'admin_init', 'myplugin_admin_init' ); register_activation_hook( __FILE__, 'my_plugin_activate' ); ?>