WP Event List Advanced

Event List (german language)
Event List (german language)

This WordPress plugin displays all available upcoming events in a sideboard widget. All events are managed in the WordPress admin page.

Event List management side
Event List management side

You can add new, edit, duplicate or delete events. Additional you can edit some properties in the widget bar. You can limit the visible events (default is three upcoming events) and add location or description information to the event.

Event List widget properties
Event List widget properties

As special feature it is possible to set links as internal or external URL. Therefore, you can create promotion sites to push up selected events.

This plugin is compatible to any WP releases since WP 3.5.

WP Tiny Statistics

tiny_statistics by Mr.CrazyappleThis is a small piece of code to create a tiny blog statistic.
Two queries counts all blog posts and pages and the second counts all used images.

The third query selects the last four entries from the wordpress posts table.

SQL Part:
Selects the last four modified entries (LIMIT 0, 4). If you want to see more post increase the last number.

require_once( ABSPATH . 'wp-includes/query.php');
global $wpdb;
$table__posts = $wpdb->prefix . "posts";

$hpe_count = $wpdb->get_var("SELECT count(*)FROM ".$table__posts." WHERE post_status ='publish' and (post_type ='post' OR post_type ='page') ");
$hpe_imgcount = $wpdb->get_var("SELECT count(*)FROM ".$table__posts." WHERE post_mime_type = 'image/png'");
$sql = "SELECT `ID`,`post_modified_gmt`,`post_title`,`post_status`,`guid`, `post_type`
FROM ".$table__posts."
WHERE post_status ='publish' and (post_type ='post' OR post_type ='page')
ORDER BY `post_modified` DESC LIMIT 0, 4";
$get_articles = $wpdb->get_results($sql, ARRAY_A);

HTML / PHP Part:

<b>Last update:</b>
<?php foreach ($get_articles as $hpe_current_article) { ?>
	<br><strong><?php echo $hpe_current_article['post_type']; ?></strong>:&nbsp;<a href="<?php echo $hpe_current_article['guid']; ?>" target="_self"><?php echo $hpe_current_article['post_title'];?></a> <em><?php echo substr($hpe_current_article['post_modified_gmt'],0,10); ?></em></a> 
<?php }?>
<br></hr>
<br> published articles/pages: <b>
<?php echo $hpe_count; ?> </b>
<br> embedded images: <b>
<?php echo $hpe_imgcount; ?> </b>