Plugin “All Sites Columns for Multisite”


The new plugin available at https://wordpress.org/plugins/all-sites-columns-for-multisite/ is Multisite specific for the superadmin and adds the columns:

  • blog_id
  • public
  • archived
  • mature
  • spam
  • deleted
  • site_id

into the ‘Sites’ admin table in Network administration page, allowing this way the superadmin to sort blogs by the desired column and spot sites which are for example deleted by their owners.

The superadmin can hide the Columns, which are useless for her/him via the ‘Screen Options’ tab.

New plugin released: Easy search and use CC-licensed images for WP


The Creative Commons image search plugin for WordPress we created in Greek School Network is now available as a plugin in WordPress.org with the name “Easy search and use CC-licensed images for WP

The plugin helps you search millions of free photos using the Creative Commons Catalog API then insert the original image into content or set as featured image very quickly.

screenshot-3

The plugin’s features are:

  • Works in WordPress editor and add a button above the content text area and into the “Add Media” pop-up window.
  • Via a pop-up window, allows searching through millions of images using Creative Commons Catalog API power.
  • Allows filtering by a provider
  • Paginated results
  • Quick insert original image or thumbnail with a link to the image URL
  • Use image as a featured image for the blog post
  • WPML compatible
  • Multisite compatible
  • Translation ready (it’s already translated in Greek)
  • Tested up to WordPress 5.2 with Classic Editor plugin

As intended, we already use the plugin in https://blogs.sch.gr, which hosts more than 50.000 blogs. The plugin is available to all its blogs and users since middle May, who has been using it without any issues reported yet.

Read the complete story behind the creation of this plugin at CC Open Source Blog

 

 

Easy search and use of CC-licensed images for WordPress


In CC Open Source Blog you can find a detailed post about the plugin we made for easy search and use of CC-licensed images for WordPress, based on the Creative Commons Catalog API.

https://opensource.creativecommons.org/blog/entries/2019-07-24-cc-search-wp-plugin/

There are still many TODO tasks so, if you want to contribute, you can fork the  plugin at Githubhttps://github.com/lenasterg/wp_ccsearch

 

 

iisa2019: Cutting Edge Collaborative eLearning Services: The Case of the Greek School Network


Poster presentation: Cutting Edge Collaborative eLearning Services: The Case of the Greek School Network, by Konstantinos Kyritsis, me and Theodoros Pegiazis at IISA 2019.
Konstantinos, presenting the poster about two of the Computer-Supported Collaborative Learning (CSCL) services provided by the Greek School Network (GSN) to the Greek Schools’ community. Application of collaborative learning in blogs.sch.gr and schoolpress.sch.gr  and how teachers can use them in their classrooms.

#iisa2019

67212712_10219315731945415_64209632226181120_n

WP CC Search plugin – 0.10


Inspired by the new CC Search tool https://search.creativecommons.org/ I decided to try and make a WordPress plugin based on it. The goal was to have an image search functionality from CC licensed images into the post editor.

Test site

You can test the resulting plugin functionality at http://users.sch.gr/stergatu/wordpress/ by login as testuser, testuser and let me know what you think of it.

Plugin source

You can find the code, contribute and report bugs at  https://github.com/lenasterg/wp_ccsearch

What the plugin does:

WP CCSearch helps you search millions of free photos using the CCsearch API (https://api.creativecommons.engineering/#tag/image) then insert the original image into content or set as featured image very quickly. The plugin is inspired and based on the https://ccsearch.creativecommons.org/ and it wouldnt’t be possible without the Creative Commons Catalog API https://api.creativecommons.engineering/

After the plugin’s activation, you can see the “Image via CCSearch” button above the editor and as option into the “Add Media” pop-up window. By pressing it you can search using Latin characters for an image, browse the returned images, preview an image and its license and adjuct the image settings:

  • use of thumbnail or original image,
  • set the image link (if any).
  • Insert the image into the post or as featured image.

Screenshots:

This slideshow requires JavaScript.

You can try the plugin and let me know what you think of it.

https://github.com/lenasterg/wp_ccsearch

BP Group Documents version 1.12.3


Just updated the BP Group Documents plugin, which creates a page within each BuddyPress group to upload and any type of file or document. This allows members of BuddyPress groups to upload and store files and documents that are relevant to the group.

Version 1.12.3 update contains the following bug fixes:

  • Fix a PHP 7.2 warning
  • Fix BuddyPress warning, thanks to @venutius
  • Fix a CSS issue reported in wordpress.org support forum

You can find the plugin in the WordPress.org repository  in https://wordpress.org/plugins/bp-group-documents/

 

 

 

New version of Sch.gr Commons plugin


We updated the plugin Sch.gr Commons https://wordpress.org/plugins/schgr-commons/  to work as it should with the recent HTTPS change of video.sch.gr 

The plugin adds oEmbed support in WordPress posts, pages and custom post types for videos, presentations etc from the https://video.sch.gr, mmpres.sch.gr sites of Greek Schools Network.
There are no settings. Simply, add the URL in your content editor.
Just paste the given “Απευθείας σύνδεσμος” link from the “Κοινοποίηση” section of a video from video.sch.gr into the content area and it will by transformed to oEmbed into your post, page or custom post type.

screenshot-3

Extend SiteOrigin slider with hide frames functionality


The SiteOrigin Widgets Bundle is one of my favorite plugins, not only because it has a bundle of widgets, but also because it is very extendable and allows other developers to customize and add more features to each widget. Moreover the guys of Siteorigin also provide a guide on how to extend the plugin (see https://siteorigin.com/docs/widgets-bundle/)

Recently I wanted to use the slider of the SiteOrigin Widgets Bundle but I also wanted to be able to  hide a frame or two – not deleted, which is the default option if you don’t want to display them anymore. Hiding and not deleting frames is a useful  feature when you have frames for  special occasions and don’t want to recreate them each time you need them.

The only thing needed is a checkbox “Hide this frame” into the frame’s tab, which then should be “be respected” by the rendering function of the slider, so the specific frame won’t be displayed.

hide_frame
The SiteOrigin slider widget’s settings with the “Hide this frame” functionality added.

So the addition of this extra functionality in the SiteOrigin slider turn out to be very easy.

All you have to do is to add the following code into your theme’s functions.php file


<?php
/**
*
* @param array $form_options
* @param type $widget
* @return array
*/
function ls_extend_sow_slider_form_add_hide_frame($form_options, $widget) {
$form_options['frames']['fields']['hide_frame'] = array('type' => 'checkbox',
'label' => __('Hide this frame', 'so-widgets-bundle'),
'default' => false,);
return $form_options;
}
add_filter('siteorigin_widgets_form_options_sow-slider', 'ls_extend_sow_slider_form_add_hide_frame', 10, 2);
/**
*
* @param type $instance
* @param type $args
* @return array
*/
function ls_slider_hide_the_hidden_frame($instance, $args) {
$frames = empty($instance['frames']) ? array() : $instance['frames'];
if (!empty($frames)) {
foreach ($frames as $i => $frame) {
if ($frame['hide_frame']) {
unset($frames[$i]);
}
}
$frames=array_values($frames);
foreach ($frames as &$frame) {
$link_atts = array();
if (!empty($frame['new_window'])) {
$link_atts['target'] = '_blank';
$link_atts['rel'] = 'noopener noreferrer';
}
$frame['link_attributes'] = $link_atts;
}
}
return array(
'controls' => $instance['controls'],
'frames' => $frames,
);
}
add_filter('siteorigin_widgets_template_variables_sow-slider', 'ls_slider_hide_the_hidden_frame', 10, 2);

 

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:

user_d

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.


<?php
/**
* Add the user id column after the user's checkbox
* @param array $array
* @param int $index
* @param array $insert
* @return array
*/
function ls_array_insert($array, $index, $insert) {
return array_slice($array, 0, $index, true) + $insert + array_slice($array, $index, count($array) – $index, true);
}
/*
* User id Column content
*/
function ls_user_id_column_content($value, $column_name, $user_id) {
if ('user_id' == $column_name) {
return $user_id;
}
return $value;
}
/**
* Make user id column sortable.
*
* @param Array $columns The original columns
* @return Array $columns The filtered columns
*/
function ls_user_id_column_sortable($columns) {
// Add our columns to $columns array
$columns['user_id'] = 'ID';
return $columns;
}
/**
* Set column width
*/
function ls_user_id_column_style() {
echo "<style>.column-user_id{width: 3%}</style>";
}
add_action('admin_head-users.php', 'ls_user_id_column_style');
add_action( 'admin_init', 'ls_user_id_colunm_show' );
function ls_user_id_colunm_show(){
if ( ! is_multisite() ){
add_filter('manage_users_columns', function ( $columns ) {
return ls_array_insert($columns, 1, array('user_id' => 'ID'));
});
add_filter('manage_users_custom_column', 'ls_user_id_column_content', 10, 3);
add_filter('manage_users_sortable_columns', 'ls_user_id_column_sortable');
}
else{
add_filter('manage_users-network_columns', function ( $columns ) {
return ls_array_insert($columns, 1, array('user_id' => 'ID'));
});
add_filter('manage_users_custom_column', 'ls_user_id_column_content', 10, 3);
add_filter('manage_users-network_sortable_columns', 'ls_user_id_column_sortable');
}
}