
Tremendous idea! I haven’t worked out all the details in my head yet, but that suggestion sounds like a keeper.
I love this new snippet! A few suggestions on the comming filter parameter:
It would also be great if the new filter function could filter on what webgroup the user is in.
Hmmm. That is interesting. I will have to look into session handling to see if there is a quick way to determine if a user is still online without even querying the database. I might try to see how SMF does it.
And maybe the filter could find users that are logged in, then it’s possible to have a list of online users.
When viewing a profile, it would be nice to see if the user is online.
That I am not sure of yet. Maybe a better method would be &list=`List Name:sortby:sortOrder:list,of,columns:` separated by double pipes.
Would multiple lists on same page work?
Sounds like you have missed the ®Required parameter. This specifies the required fields. If you are using the default "instant" form, a suggestion would be to use ®Required=`email,username,fullname,password,formcode,toc` in your snippet call.
These are things that exists in PPP, if they would be implemented in WLPE it would be possible to migrate to WLPE for existing PPP-users. And I wouldn’t have to feel bad any more for not continuing working on PPP
One question: I just started to test WLPE, but on the (instant) register page I get no warning messages, what have I missed? (Perhaps I should test this on e real server instead of Xampp.)
Quote from: Soshite at Sep 02, 2007, 08:48 AMBy "Admins" are you referring to:
I noticed in Uncle68’s PPP thread that he was reconmending PPP users to use WebLoginPE. I’d be willing to switch over to it, but I need to know a few things first...
1) In PPP, there is the ability to have certain fields that only Admins can edit? As an example, on my website, I have Achievements for stuff like submitting graphics or game information. I need an easy way to add them for my users (going into phpMyAdmin could get annoying after a while, just to add an Achievement.
- Managers, from the Backend.
- Members of the webgroup "Admins"
- or Members of a webgroup that was specified in the snippet call?
Quote from: Soshite at Sep 02, 2007, 08:48 AMIntersting.
2) In PPP, people can "sort" users by those who have a website, or have an AIM account. This is basically done by adding a filter in the PPP snippet call, like website or aim. Can this be replicated in WebLoginPE?
I have been working on a parameter called &sortBy (and of course &sortOrder [ASC:DESC]) for the WebLoginPE &type=`users` call. This parameter will accept one argument, a table column name such as username, lastlogin, internalKey, etc..., and will sort the entire list of users by the value of that column.
I love your idea and I will implement the &filter parameter for the users list which will accept a comma separated list of table column names to filter. If the user has data stored in all the columns specified, they would be shown in the list, else they would be excluded.
So if you wanted to show all the users who entered their AIM account you would use &filter=`aim` (assuming the customField you used was "aim". If you wanted to show all the users who entered a website AND a phone number, then sort them by date of birth, you would use &filter=`website,phone` &sortBy=`dob` &sortOrder=`ASC`
Just thinking out loud here, but... Yeah... I like that idea
-sD-
Dr. Scotty Delicious, Scientist.
http://tales.rpgplanet.gamespy.com/mysymphonic/account_admin.php?WEDIT=18
I will create a new WebloginPE type (&type=`manage`) It will create a page much like &type=`users` where all the users are listed (or sorted and filtered) and each user image/username would be a link to an area where those with permission to view the page could modify user settings. As with all views in WebLoginPE, this could use a custom template with form inputs for whatever database fields you want to manage.
1) I created a Web User Group called Administrators. Then, I created a duplicate of the page webusers use for editing their account, and restrict it so only the "Administrators" group can access it. Then I just add the extra fields I need, like the Achievements, as checkboxes. Now, to be able to edit other people’s profiles, I would have to use this type of URL...
http://tales.rpgplanet.gamespy.com/mysymphonic/account_admin.php?WEDIT=18
...and WEDIT is whatever user you need to edit, using their ID. I like having the Admin Web User group, simply because I don’t have to be logged into the Manager to do it, and with WebLoginPE, I’m always logged in, so I can edit profiles quickly on the fly.
WebLoginPE does grab all the data from the "web_user_attributes" table, but you can also specify &customTable=`table_name` and WebLoginPE will automatically create the table for you if it is not already there.
2) I like the &sortby option...that’s something that I don’t remember seeing in PPP. BTW, with WLPE’s custom tables, is that in the normal attributes table, or in a custom table that I need to create --- if so, then if we were able to specify which table it used, PPP users could very easily transfer over to WLPE with no problems (like for instance, IIRC, my custom table for PPP is web_user_mysymphonic).
WebLoginPE has a special method for handling inputs of type <select>, <select multiple>, <input type="radio"> and <input type="checkbox">.
Small question, but I remember in PPP, with how it used EForm to input the data into the database, fields like textareas, checkboxes, and radio buttons wouldn’t show the data from the database, which made problems when someone edited their profile, which would wipe the data in a textarea (like a bio for the user). Oddly enough, this didn’t affect checkboxes and radio buttons. Does WLPE get affected by this issue, or is it immune since it doesn’t rely on EForm, IIRC?

[!WebLoginPE? &type=`profile` &profleTpl=`myProfileForm` &customFields=`vehicletype,favorite_colors,contact_time,emailprivate` &inputHandler=`Your Vehicle Type:userVehicle:vehicletype:select:Compact(compact),Van(van),Light Truck(light_truck),SUV(suv) ||Favorite Colors:userFavoriteColors:favorite_colors:select multiple:Red(ff0000),Orange(ff9900),Green(66ff00),Black(000000) ||Best time to contact you:userContactRadios:contact_time:radio:Morning(morning),Afternoon(afternoon),Evening(Evening) ||Keep my email private:userPrivateEmail:emailprivate:checkbox:()`!]
<div id="wlpeUser">
<form enctype="multipart/form-data" id="wlpeUserProfileForm" action="[~[*id*]~]" method="POST">
<fieldset id="wlpeUserProfileInput">
<div id="wlpeUserInfo">
<h3 id="wlpeProfileWelcome">Hello [+user.fullname+] ([+user.username+])!</h3>
<p id="wlpeProfileInfo" class="info">Use this form to update your profile information</p>
</div>
<legend>Your User Profile</legend>
<label for="wlpeUserProfileFullName">Full Name
<input id="wlpeUserProfileFullName" type="text" name="fullname" value="[+user.fullname+]" />
</label>
<label for="wlpeUserProfileEmail">Email
<input id="wlpeUserProfileEmail" type="text" name="email" value="[+user.email+]" />
</label>
<label for="userPrivateEmail" id="userPrivateEmailLabel">Keep my email private
<input type="checkbox" name="emailprivate" id="userPrivateEmail" />
</label>
<label for="userVehicle" id="userVehicleLabel">Your Vehicle Type
<select id="userVehicle" name="vehicletype">
<option value="compact">Compact</option>
<option value="van">Van</option>
<option value="light_truck">Light Truck</option>
<option value="suv">SUV</option>
</select>
</label>
<label for="userFavoriteColors" id="userFavoriteColorsLabel">Favorite Colors
<select multiple id="userFavoriteColors" name="favorite_colors">
<option value="ff0000">Red</option>
<option value="ff9900">Orange</option>
<option value="66ff00">Green</option>
<option value="000000">Black</option>
</select>
</label>
<label for="userContactRadios" id="userContactRadiosLabel">Best time to contact you
<div id="userContactRadiosDiv">
<input type="radio" name="contact_time" id="userContactRadiosMorning" value="morning" />
<span class="userContactRadiosSpan">Morning</span>
<input type="radio" name="contact_time" id="userContactRadiosAfternoon" value="afternoon" />
<span class="userContactRadiosSpan">Afternoon</span>
<input type="radio" name="contact_time" id="userContactRadiosEvening" value="evening" />
<span class="userContactRadiosSpan">Evening</span>
</div>
</label>
</fieldset>
<fieldset id="wlpeUserProfileButtons">
<button type="submit" id="wlpeSaveProfileButton" name="service" value="saveprofile">Save</button>
<button type="submit" id="wlpeProfileDoneButton" name="service" value="cancel">Done</button>
<button type="submit" id="wlpeProfileLogoutButton" name="service" value="logout">Logout</button>
<button type="submit" id="wlpeProfileDeleteButton" name="service" value="deleteprofile">Delete My Profile</button>
</fieldset>
</form>
</div>
<div id="wlpeUser">
<form enctype="multipart/form-data" id="wlpeUserProfileForm" action="[~[*id*]~]" method="POST">
<fieldset id="wlpeUserProfileInput">
<div id="wlpeUserInfo">
<h3 id="wlpeProfileWelcome">Hello [+user.fullname+] ([+user.username+])!</h3>
<p id="wlpeProfileInfo" class="info">Use this form to update your profile information</p>
</div>
<legend>Your User Profile</legend>
<label for="wlpeUserProfileFullName">Full Name
<input id="wlpeUserProfileFullName" type="text" name="fullname" value="[+user.fullname+]" />
</label>
<label for="wlpeUserProfileEmail">Email
<input id="wlpeUserProfileEmail" type="text" name="email" value="[+user.email+]" />
</label>
[+form.emailprivate+]
[+form.vehicletype+]
[+form.favorite_colors+]
[+form.contact_time+]
</fieldset>
<fieldset id="wlpeUserProfileButtons">
<button type="submit" id="wlpeSaveProfileButton" name="service" value="saveprofile">Save</button>
<button type="submit" id="wlpeProfileDoneButton" name="service" value="cancel">Done</button>
<button type="submit" id="wlpeProfileLogoutButton" name="service" value="logout">Logout</button>
<button type="submit" id="wlpeProfileDeleteButton" name="service" value="deleteprofile">Delete My Profile</button>
</fieldset>
</form>
</div>
Hmmm...
Hi Scotty,
WebloginPE sounds really interesting and powerful.
Just a thougt about inputHandler.
What about writing the params in the chunkForm instead of the snippet params.
[+form.vehicletype:select:Compact(compact),Van(van),Light Truck(light_truck),SUV(suv)+]
And it Would be awesome to include the @BINDINGS support to fill the options list

