Another slew of features to show off!

SocialEngine - Community Software

This week I’ve been adding features at a break-neck pace! Without further ado, here are some previews:

1. One of the features that has been requested is the ability for the admin to disable “Delete Account” page and to disallow username changing. I’ve added that feature in the user level area:


2. I’ve also been working on adding (and improving upon) some of the tutorials that were made for v2.X. One is Guests in Online Users List tutorial. I improved it a bit in the platform, but it is essentially the same feature.


3. Another tutorial I implemented is the Slick Autogrowing Textboxes tutorial. Again, I optimized it a bit for SE3, but it is still one slick-looking feature!


4. Finally, I implemented (and greatly improved) the Sample Profile CSS tutorial. For one, I added an admin option to turn on/off these samples (which are now stored in a database table instead of in a subdirectory on your server:


The luxury this affords you as admin is that you can allow users to have “different” profiles without letting them specify their own CSS. If you turn off the Custom Profile CSS textarea but leave the Sample CSS feature enabled, your users can choose from the samples you have for their profile. If you were ever concerned about CSS security or design-breakage, this is an easy way around it!


Note that Alex is going to make the “highlighted” sample look nicer – I’m no where near as good as he is at design-work πŸ™‚

5. As I’ve mentioned before, we’ve added some comprehensive language management features in v3. Now your anonymous users will be able to choose their language via a select box (assuming you’ve enabled the setting).

6. Many of you have requested a way to shut your site down for maintenance and upgrades. So here it is!


Notice that it says that if you are logged in as the admin, you can still browse the site freely. This is so that you can test any features you’ve added or modified before you bring your site back online.

7. I finally added “Checkboxes” to the types of profile fields you can have! In the admin section, it will work very similarly to radio buttons and select boxes (where you add your options, and can specify a dependent field). In the user area, they will be able to check as many checkboxes as they want:


And on the profile, they will show up as a comma-delimited list (in the screenshot below, they are also “linked” for browsing).


8. Last, but not least, I have added the ability to modify the FAQ easily. It isn’t quite wFAQ, but it’s the same idea. Here’s the admin section:


You’ll notice that you can see how many views each question has received as a daily average (if you hold your mouse over the link, you can see the total over all, and if you click you can reset the views). In the user section it looks essentially the same as it did before.

That’s all I’ve got for you in the way of additional features. I have a couple of questions I’d like the community opinion on. Here they are:

1. I know there are many of you who have asked to allow additional characters in emails. I think at the moment we are not allowing underscores, which is silly – I am sure there are other characters that are allowable in emails that we are missing. Anyone have any ideas on this topic?

2. I have changed the “field_birthday” column in the database to “field_special” with the intention of allowing the additonal fields that are treated differently than they might otherwise be. Right now, if you have a date field and check the “birthday?” box, that field will be treated as the user’s birthday and it will display the user’s age. Another example might be a “Zip Code” – we won’t be adding it in v3, but in theory if you had a zip code field, it would allow you to do proximity searches, or display on a given user’s profile how many miles away from you they live. My last idea was to have “First Name” and “Last Name” (or “Display Name”) special fields, so that we could display the user’s full name on their profile (as I know so many of you have requested). Anyway, I am just brainstorming this, and I was wondering what ideas you guys had regarding this topic. I may not add anything besides “Birthday” right now, or I may decide to add a few more, I can’t make any guarantees.

Now that that’s all out of the way, I thought I’d leave you all with something I think is really cool that you can do with SE. Suppose you wanted to display how many users you have on your network on a page, let’s say the user_home.php page, for example. Those of you that know a little (or a lot) about PHP or Smarty might imagine that you would open up user_home.php, add a database query that calculates how many users you have, then assign a smarty variable that can then be used in the TPL file. This is how we do most things in SE.

But! There is actually a really cool way that you can do it without ever opening the PHP file! Check it out – open up your TPL file (user_home.tpl, in this case, or wherever) and put this in:

{assign var=”total_users” value=$database->database_fetch_assoc($database->database_query(“SELECT count(*) AS total FROM se_users”))}
Total Users: {$}

Because the $database object is passed through to the Smarty template, we can actually run database queries by putting them directly -in- the Smarty Template!

Why is this cool you ask? Well, for one thing, those of you running the trial could actually push your SE installation a little further. Those of you making tutorials (for “Recent Blog Entries” for example) could simplify everything, if you wanted, into a change in a single file. Those of you who hate, hate, hate upgrades because you have made modifications to your PHP AND TPL files might be able to reduce your misery a bit by making changes to only the TPLs where you can. Anyway, we don’t use this nifty feature in SE much because we have the luxury of having access to the PHP files and knowing how to code in PHP. This might be a cool way for those of you that don’t know PHP to learn a little about databases without needing to muck around in the PHP files. Or maybe it’s not actually of any use to you guys, but I thought it was cool and figured I would share πŸ™‚

Leave a Reply