I guess I meant the Users API, not the module itself. Actually, the administrative interfaces for user management are much improved. But a number of my modules contain signup and account management interfaces, and they talked directly with the pn_users database to accomplish this (rather than using the native PostNuke 0.7x account management tools). Obviously this is not the preferred route! But there was no API support for user management in 0.7x.
I had hoped that in 0.8 there would be an API for managing user data (e.g. Users_adminapi_create, Users_adminapi_update, Users_userapi_getall, etc.), but no such luck as far as I can tell. So for the modules that deal with user accounts, I'll have to figure out how Users manages data and duplicate that in a library so that my modules will be able to interact with PN 0.8's user database.
It now occurs to me that this part of the discussion isn't related to the Sites Showcase forum. I hope the Powers That Be will forgive this divergence.
edited by: bbirney, Apr 22, 2008 - 05:00 PM
--
--
Ben Birney
http://www.tilsontech.com/
http://www.sophiasfall.com/
Watch
GitHub Core
Show your support for Zikula! Sign up at Github account and watch the Core project!
GitHub Modules
- mazdev responded to »Hide "Register new account" and change template to 3 col« 07:50 AM
- mesteele101 created topic »Zikula 1.3.3 - Site Search 1.5.2 - Unable to turn off plug-ins« 07:48 AM
- internetking created topic »password problem« 25. May
- mesteele101 responded to »ERR (3): E_USER_ERROR: Smarty error: [in pagesvar:pagesitem2en line XXX]…« 25. May
- mazdev responded to »Pages 2.5.0 and updating - Page not found« 25. May
- mesteele101 responded to »Zikula 1.3.3 - Selecting a category in Pages not working« 25. May
- mdee created topic »How to implement returnpage ?« 25. May
Zikula Blog
- Anatomy of Open Source Projects on Mar 07
- Continuous Review on Mar 01
- Not Invented Here on Feb 24
- How to Contribute Your Code at Github on Jan 13
- 10 Steps to Coding-Nirvana: Tips for Successful Module Writing on Nov 12
- Submitting Bug Report Tickets That Get Results on Aug 17
- Cozi Tricks #1: Syntax Highlighting on Aug 07
Login
Users module APIs
-
- Rank: Registered User
- Registered: Apr 23, 2004
- Last visit: Feb 07, 2010
- Posts: 30
-
- Rank: Team Member
- Registered: Mar 18, 2002
- Last visit: Oct 21, 2009
- Posts: 6606
Most of the API functions you need should be there - check the documentation. A few aren't quite named the same but all the basics seem to be there.
-Mark
--
Visit My homepage and Zikula themes. -
- Rank: Registered User
- Registered: Apr 23, 2004
- Last visit: Feb 07, 2010
- Posts: 30
You're right, Mark, the userapi are there, my mistake. I haven't yet been able to discover the critical adminapi functions, though, that would let me create and edit users, which are the most important functionality I'd need to rebuild my module library to be 0.8 compatible.
Just as an example, users_adminapi_saveuser() might initially appear to be an analog of users_adminapi_create() - but on closer inspection, it appears to be expecting form input, and performs additional operations other than simply checking and saving the data. As an active module developer, what I really need is your basic "add/edit/delete" functionality, without all the additional action. I realize that all this is needed for the core PN 0.8 users system, but it still seems like something is missing from Users - the low-level abstraction layer that would just provide an interface into the database and let the calling module worry about the rest of the operational details.
I'm not saying it's not a step forward from 0.7x - it certainly is. Previously my user-related modules had to write directly into pn_users! It just doesn't seem to have gotten quite to the level of flexibility that's needed for a true application framework.
Perhaps I'm missing something. Is DBUtil::updateObject() that magical low-level abstraction I'm looking for?
--
--
Ben Birney
http://www.tilsontech.com/
http://www.sophiasfall.com/ -
- Rank: Team Member
- Registered: Mar 18, 2002
- Last visit: Oct 21, 2009
- Posts: 6606
From a quick look it looks as though create is finishnewuser and update is saveuser. The update function looks ok to me - theres only sanity checks here. The create API does a little more than i'd like - such as e-mailing the user password. Splitting the actual create user code into another API probably makes sense here.
In terms of DBUtil - updateObject will update a DB record and insertObject will create one.
-Mark
--
Visit My homepage and Zikula themes.
- Moderated by:
- Support
Users on-line
- 0 users
This list is based on users active over the last 60 minutes.
