multisite, wordpress

Add a sortable user Id column into WordPress Users table

Sometimes it is useful to find the user_id of each user you have in your WordPress site.  This is especially helpful if you have a multisite with a lots of users.  Something like this:


In order to have that kind of functionality,  you can add the following code in your theme’s functions.php.
If you have a multisite installation the ID column will be only displayed in the network users admin page and not in each subsite’s users admin table.


debugging, Uncategorized

How to know what functions are hooked to an action/filter?

A very useful function if you need to know which functions are hooked to a particular hook and where the functions are located. Found in stackoverflow, answer of Danijel



Override bp-signups view with pending users view from ‘new user approve’ plugin

Using BuddyPress and New user approve plugin is a bit confusing for the admin, cause the “pending” users link on top of  users table in admin page, points to BuddyPress pending users. But when the ‘New user approve’ plugin is activated, the pending users are shown in a different page.

In order to fix the link “Pending” displayed on top of the users table, the following filter is needed.


Add download funtionality to Royal PrettyPhoto plugin

A way to extend Royal prettyPhoto plugin to support download image functionality is via Javascript.

Just put the following lines into the functions.php of your theme file.

 * Adds download functionality to prettyPhoto plugin
 * @author lenasterg
function ls_prettyPhoto_Download() {
 echo '<style>.pp_download{ background: #ccc; border-radius: 3px; height: 25px; padding: 4px;}</style>

jQuery(document).ready(function() {
 changepicturecallback: function(){
 $getit= settings.image_markup.replace(/{path}/g,pp_images[set_position]);
 jQuery(".pp_pic_holder").find(\'.pp_details .pp_download_place\').html(\'Download\');


You can download the above code also from gist:


Email to superadmin when a subsite has low available space

Since part of my job is to support a very, very large multisite (and multiuser) WordPress installation, I deal daily with user’s requests and problems.

One of the most frustrating things for them and me, is when the available space of their blog is low. They have to report it to our helpdesk and then wait till we increase it.

Since I couldn’t find a plugin which notice the network admin about low space in subblogs,  I wrote a simple function which does it.

The function sends an email to the network admin when the available space is less then 200MB. It runs every time the blog admin visits the control panel of his/her’s blog.
Just add the following code in your custom.php file.

* Send email to super admin when the blog's available space is less than 200MB
function ls_blog_space_mail() {
$space_left = round( get_upload_space_available() / 1024 / 1024 );
if ( $space_left < 200 ) {
$message = 'Site ' . get_site_url() . ' has only ' . $space_left . 'MB space left. '
. 'If you wish to expand the available space visit ' . network_admin_url( 'site-settings.php?id=' . get_current_blog_id() ) . ' and increase the "' . __( 'Site Upload Space Quota' ) . '."';
wp_mail( get_site_option( 'admin_email' ), "[ " . wp_specialchars_decode( get_option( 'blogname' ) ) . " ]. Low available space", $message );

if ( is_multisite() ) {
add_action( 'activity_box_end', 'ls_blog_space_mail' );

Or find it in github

multisite, my plugins, wordpress

Build it with Show it in your WordPress site

icon-256x256With Scratch (, you can program your own interactive stories, games, and animations – and share your creations with others in the online community. Scratch helps young people learn to think creatively, reason systematically, and work collaboratively – essential skills for life in the 21st century.

Now, with LS oEmbed support for Scratch Mit  you can just copy-paste the URL from a scratch project into the content area of a post or page
and it will by transformed to oEmbed.

This oEmbed functionality was initial build for the Greek Schools Network blogging platform ( and now it is available for all via the WordPress repository in

The plugin is a useful addon for educational WordPress sites.

greek, Uncategorized, wordpress

WordPress 4.4 “Clifford” – Fully translated in more than 40 languages

At you can read all the new features version 4.4. has to make your site more connected and responsive.

Also this version is already available in more than 40 languages (if you count all English “versions” too).

Among them is also the Greek version!!! I’m so proud to be part of the Greek translation team

Thanks to all teammates and our editors ♥ ♥ ♥