API Question

Creating and modifying plugins.
Post Reply
Posts: 19
Joined: Wed Feb 02, 2005 8:46 pm

API Question

Post by boelkstoff » Tue Feb 08, 2005 2:26 pm

As you have probally notice I love s9y and the cool plugin system.
I am looking for a way to find out what user is currently logged in.
In another plugin I have found:

Code: Select all


which tells me if a user is logged in.
How can I found out which user is logged in (userid) and what his rights are (e.g. 0 oer 255).

Why am I asking? Well I since my guestbook is almost done, I am thinking about an extendes user plugins which allows user to enter extra data like adress or phonenumber, which can other user view. I know this is not the purpose of a weblog, but I will probally need that in the future. So it would be nice.


P.S. It would be nice if you would have a document (whcih can everybody edit, like the "who is using") , where someone can right down some api things that he/she found out, so other people can look and browse and do not need to ask the question again.

User avatar
Core Developer
Posts: 30020
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany

Re: API Question

Post by garvinhicking » Wed Feb 09, 2005 12:27 pm


You can access

Code: Select all


for that. Those are defined within include/functions_config.inc.php, function serendipity_authenticate_author().

So have fun with that, and great to hear you like Serendipity :-)

Basically our Wiki should support the creation of new documents within "User documentation", since that one is globally writeable. If it doesn't work, blame coWiki :-D

# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/

Post Reply