Easy wp guide PDF for your wordpress customers

we do WordPress developement for developers but also for our final customer, the web site owner. And even with a platform easy to use like WordPress, it can be good to provide basic instructions and written notes for content management. Usually I write specific tutorials for my customers but I have to admit that the Easy WP GUIDE is a good example of what I could give to all my customers. It is written and distributed in pdf version for free by Anthony Hortin, web developer from Melbourne Australia

Using Amazon S3 cloud storage with WordPress

I was quickly hooked to Amazon S3 storage via the free account creation offer on Amazon Cloud's website. AWS offers 5 free gigabytes of cloud storage, which is interesting if, as in my case, you need to host big files permanently, that could hardly be stored via standard wordpress installation. Of course you could increase upload limit but I am afraid this could be  security issue.

It turns out that the AMAZON WEB SERVICES is a cluster of different hosted applications, among which S3 is the simplest to use : it is no more than a file storage utility with a web based browser, web access to files, and various protection features.

If you want to host your WORDPRESS Media files on AMAZON S3, you need to install a plugin. I tried the WP READ ONLY plugin that is very easy to configure. All you need is to have configured  your S3 account :

  • choose a bucket   (some kind of folder for amazon S3),
  •  your amazon credentials : developer key and SECRET KEY

Other plugin I tried is wp2cloud but this one is more complex to configure as it requires linux skills to install Clouse,  Cloud Storage Engine for MySQL

Complex layout operations with wordpress

Building enterprise web sites from various graphic models involves two different level of customisation within the wordpress framework.

Page and post templates in wordpress

Themes are pieces of code aggregating various page types : archive pages, single post display, single page display. Most commonly all models of a theme share the same header and footer, and depending on specific coding operations, the same menu from the wordpress menu system. The theming system allows a lot customization options, including the possibility to define page templates for letting editors choose, for example, between full size page and 2 column page with widget enabled margin.

In native wordpress, this templating modification works only for pages. if you need to do this for posts, you need to install a specific extension "Custom Post Template" that will let you define specific post template, the same way you do for pages, by writing specific php template with instructions in the header comments.

Multi theming your site

Considering possibilities described above, multiple theming raises a lot of issues. The plugin JonRadio multiple theme comes with many configuration options to define specific theme for pages or sections. It has a big drawback though : it does not integrate theme options for the second theme, like widgets or menu, or other options.

php opensource cms 2013 06

  • http://getfuelcms.com/home gets released version 1
  • http://www.novius-os.org/ based on fuelphp
  • ametys.org

still wordpress is unbeatable at content management use, it lacks serious user features in its default configuration

5 Responsive Sliders plugins for WordPress with Touch Swipe Gestures

5 Responsive Sliders plugins for WordPress with Touch Swipe Gestures

An Image is capable of conveying thousands of feeling one the first look. The Right image gallery would definitely be the multiplying factor for your business clients as well as customer satisfaction. Definitely it is the best medium to showcase your complete range of products and services to your potential clients. With the advent of the WordPress more and more web businesses are making their way to use this most effective platform for their business.

Also similarly with the increase in the mobile devices such as iPhone, iPad and Android it is quite difficult for the designers to make their content to be compatible with these devices. Below are mentioned some of the leading plugins for the WordPress having the touch swipe feature which will completely change the way you do your business.

All these plugins are the responsive sliders and will integrate with your business to perfection.    


The plugin basically gives you the best responsive taste without any trouble.  Many developers are using this open source plugin and certainly it has the thumb swipe feature for the mobile devices. Among the features of it are that it is responsive as well as it is IE7+ compatible. Along with that it supports all the Galley API’s such as previous, next, slide number and many more. It is best for callbacks and External API customization.

  Kenburner Slider WordPress Plugin


It is the dynamic combination of the text animation, Ken burner effects, versatile sliders and responsive features. You can really customize this slider as per your needs with a little CSS and HTML changes. It can be used with the thumb swipe gestures. It is easy to install and can be easily resized in terms of thumbs and images.


PhotoSwipeThis plugin for the WordPress is the most widely used plugin and no doubt it is mainly for the mobile devices. It is a HTML/ CSS/Java script based image gallery which is full responsive and touch compatible with the mobile devices. The plugin is basically open source and have many API’s which make it the famous option among many users. It is best optimized for the touch devices.


The plugin is certainly easy to use and is one of the best responsive types of plugin. Some of the features of it are content slider, animated captions, responsive layout, touch support and many other features. For the navigation purposes you can use the thumbnails, tabs or bullets. You can use it banner rotator, gallery, content slider, video gallery, HTML content, slide show and various other types of purposes.

  Galleria –Responsive Java Script Image Gallery

It is basically the Java Script framework that simplifies the process of the creation of the beautiful images and galleries for web applications. The plugin is best for the responsive panel and it is free without any type of restrictions. Also it is touch swipe friendly and a comprehensive documentation is available. There is the option for the multiple themes along with the one core theme.

The above plugins are best responsive for the WordPress. All of them have the touch swipe optimization and can be customized for every type of device by the user as per the requirements.

Author Bio

Claudia has written on a number of articles on the  Microsoft SQL Server Training highlighting its importance in the business and IT world. The author tries to make the reader accustomed to every dimension of this task follow me on Twitter, Facebook & Google+.

cyclone slider : add page num setting

The Cyclone slider plugin for wordpress is one of the best free plugins available for making sliders within pages and posts. Apart from dealing with slides within a drag and drop framework, it also features a list of parameters for each slider, but the possibility to use numbers in the slide pagers is currently missing. it is very easy to add, so I put the code below until a new release comes with that feature.

 Note : before using the code below make sure you upgrade cyclone slider to the latest version of jcycle2  

  • in inc / admin parts/ slider-properties, add the html code to display the input field 

    <!--webmasterbulletin.net 20130505 add pagenum settings-->
    <div class="cycloneslider-field">
    	<label for="cycloneslider_settings_randomize"><?php _e('Pager / slide num ?', 'cycloneslider'); ?></label>
    	<select id="cycloneslider_settings_slide_num" name="cycloneslider_settings[slide_num]">
    		<option <?php echo (0==$slider_settings['slide_num']) ? 'selected="selected"' : ''; ?> value="0"><?php _e('No', 'cycloneslider'); ?></option>
    		<option <?php echo (1==$slider_settings['slide_num']) ? 'selected="selected"' : ''; ?> value="1"><?php _e('Yes', 'cycloneslider'); ?></option>
    	<span class="note"><?php _e('display slide num in pager.', 'cycloneslider'); ?></span>
    	<div class="clear"></div>
    <!--webmasterbulletin.net 20130505 add pagenum settings-->
  • in class-cyclone-slider, add the save value code in save_settings function
      $settings['slide_num'] = (int) ($_POST['cycloneslider_settings']['slide_num']); //webmasterbulletin.net20130505
  • and in the same file add the get setting code in  the shortcode function : 
    $slider_settings['slide_num'] = $this->get_comp_slider_setting($admin_settings['slide_num'], $shortcode_settings['slide_num']); //webmasterbulletin.net20130505
  • finally in functions.php, add the jcycle setting if the cyclone slider setting is on in cyclone_settings function

    if ($slider_settings["slide_num"])$defaults['data-cycle-pager-template']="<strong><a href=#> {{slideNum}} </a></strong>"; //webmasterbulletin.net20130505

wordpress : protect file download to registered users only

In this article we will explore a set of code hooks into the worpdress customization framework. The aim of this technique si to hide pdf documents from search engines and non connected users,  and to present them with a custom  login page if not connected, that would redirect directly to the file download after identification (login) via this custom login page.

  • STEP1:  block pages for non registered users
    • to block a page from non registered users, page editor must set a custom field "block" set to 1.
  • present non registered users with form on protected pages
    • we filter the content (the_content)   and return a login form if user is not connected for pages. the login form is included in a specific file po_login_form
  • create specific pdf download link for first page attached PDF, with docid as get variable
    • on your page template, use a query to find your pdf (page attachment) object, once you have that pdf object you can use it to make your url depending on the login status: 
if (is_user_logged_in()) $urlPDF=$pdf->guid; else $urlPDF="/utilisateurs/identification/?docid=" . $pdf->ID;
  • redirect to file if get variable is set
    • add the po_redirect_after_login function the init filter. This function will test the docid   get variable, find  the corresponding pdf attachment and redirect to this attachment url if found and user is logged in, otherwise does nothing and lets the_content filter do its job presenting the login form.

wordpress 3.5 major image management improvement

Media tags and File Gallery : two main plugins for image management that are not so necessary now, as wordpress 3.5 comes with a new image management tools, that's really impressive,  whose killer feature is the possibility to choose, drag and drop images for native gallery creation, not just images from the post, but possibility of selecting any set of image for a specific gallery among many if necessary within post / page. What I need to test now is the media tag plugin for backward compatibility and the file gallery plugin that was allowing me to build galleries from a drag and drop selection of images is now uneeded. Media tags has not been updated for a year or two so I'm really concerned about this one for website upgrading to 3.5, as it relies extensively on the media interface. question opened as of now on wordpress forum.

free drag and drop slider plugins for wordpress

there are more and more drag and drop content management plugins for wordpress. I will without a doubt review some that deal with general content management, but for now I focus on sliders.

Simple ad management for wordpress

Combine wordpress custom post type and widget management to get a simple ad management system that can easily be enhanced to suit specific needs. Code below provides implementation for

  • "ad" custom post type, with thumbnail for image, and custom field in meta box for url destination 
  • widget for displaying random ad each time web site is refreshed, you can adpat image sizz by changing the image size in your code, once it has been defined in wordpress image sizes (add_image_size function)


  // webmasterbulletin : ad custom post type with widget
  // include in your theme functions.php
// Registers the new post type and taxonomy
function webmasterbulletin_ads_type() {
    register_post_type( 'ads',
            'labels' => array(
                'name' => __( 'Pub' ),
                'singular_name' => __( 'Pub' ),
                'add_new' => __( 'Ajouter pub' ),
                'add_new_item' => __( 'Ajouter pub' ),
                'edit_item' => __( 'Modifier pub' ),
                'new_item' => __( 'Ajouter pub' ),
                'view_item' => __( 'Consulter Pub' ),
                'search_items' => __( 'Recherche annonceurs' ),
                'not_found' => __( 'aucun annonceur sur ces criteres' ),
                'not_found_in_trash' => __( 'aucun annonceur dans la poubelle' )
            'public' => true,
            'supports' => array( 'title', 'editor', 'thumbnail'  ),
            'capability_type' => 'post',
            'rewrite' => array("slug" => "ads"), // Permalinks format
            'menu_position' => 5,
            'register_meta_box_cb' => 'add_wb_ad_metaboxes'
add_action( 'init', 'webmasterbulletin_ads_type' );
add_action( 'add_meta_boxes', 'add_wb_ad_metaboxes' );

// Add the Events Meta Boxes
function add_wb_ad_metaboxes() {
    add_meta_box('wpt_add_url', 'Destination', 'wb_ad_mb', 'ads', 'normal', 'high');
 // The Event Location Metabox
function wb_ad_mb() {
    global $post;
    // Noncename needed to verify where the data originated
    echo '<input type="hidden" name="adurl_noncename" id="adurl_noncename" value="' .
    wp_create_nonce( plugin_basename(__FILE__) ) . '" />';
    // Get the location data if its already been entered
    $addurl = get_post_meta($post->ID, 'addurl', true);
    // Echo out the field
    echo '<input type="text" name="addurl" value="' . $addurl  . '" class="widefat" />';

// Save the Metabox Data
function wb_save_ad_meta($post_id, $post) {
    // verify this came from the our screen and with proper authorization,
    // because save_post can be triggered at other times
    if ( !wp_verify_nonce( $_POST['adurl_noncename'], plugin_basename(__FILE__) )) {
    return $post->ID;
    // Is the user allowed to edit the post or page?
    if ( !current_user_can( 'edit_post', $post->ID ))
        return $post->ID;
    // OK, we're authenticated: we need to find and save the data
    // We'll put it into an array to make it easier to loop though.
    $events_meta['addurl'] = $_POST['addurl'];
    // Add values of $events_meta as custom fields
    foreach ($events_meta as $key => $value) { // Cycle through the $events_meta array!
        if( $post->post_type == 'revision' ) return; // Don't store custom data twice
        $value = implode(',', (array)$value); // If $value is an array, make it a CSV (unlikely)
        if(get_post_meta($post->ID, $key, FALSE)) { // If the custom field already has a value
            update_post_meta($post->ID, $key, $value);
        } else { // If the custom field doesn't have a value
            add_post_meta($post->ID, $key, $value);
        if(!$value) delete_post_meta($post->ID, $key); // Delete if blank
add_action('save_post', 'wb_save_ad_meta', 1, 2); // save the custom fields


widget for ad management

code adapted from Simple Random Posts Widget plugin

define("DefNoOfPosts", "1"); // default number of random posts to display

class SimpleRandomPostsWidget extends WP_Widget {

    function SimpleRandomPostsWidget()
        parent::WP_Widget( false, 'Simple ADS Random Posts',  array('description' => 'Random posts widget') );

    function widget($args, $instance)
        global $NewSimpleRandomPosts;
        $title =   $instance['title'];
        echo $args['before_widget'];
        echo $args['before_title'] . $title . $args['after_title'];
        echo $NewSimpleRandomPosts->GetSimpleRandomPosts(  empty( $instance['ShowPosts'] ) ? DefNoOfPosts : $instance['ShowPosts'] );
        echo $args['after_widget'];

    function update($new_instance)
        return $new_instance;

    function form($instance)

            <label for="<?php echo $this->get_field_id('title'); ?>"><?php echo 'Title:'; ?></label>
            <input type="text" name="<?php echo $this->get_field_name('title'); ?>" class="widefat" id="<?php echo $this->get_field_id('title'); ?>" value="<?php echo esc_attr($instance['title']); ?>" />
            <label for="<?php echo $this->get_field_id('ShowPosts'); ?>"><?php echo 'Number of entries:'; ?></label>
            <input type="text" name="<?php echo $this->get_field_name('ShowPosts'); ?>" id="<?php echo $this->get_field_id('ShowPosts'); ?>" value="<?php if ( empty( $instance['ShowPosts'] ) ) { echo esc_attr(DefNoOfPosts); } else { echo esc_attr($instance['ShowPosts']); } ?>" size="3" />



class SimpleRandomPosts {

    function GetSimpleRandomPosts($noofposts)
         remove_filter ( 'posts_join', 'recent_join'  );
         remove_filter ( 'posts_fields', 'recent_fields'  );
            $the_query = new WP_Query('orderby=rand&post_type=ads&showposts='.$noofposts);
           // echo $the_query->request;
            if ($the_query->have_posts()) :
                while ($the_query->have_posts()) : $the_query->the_post();
                $url=get_post_meta(get_the_ID(),"adurl", true);
                    echo  '<div align="center"><a href="'.$url.'" target="_blank">';
                    echo get_the_post_thumbnail( get_the_ID(), "largeur200", array('title'=>get_the_title(), "alt"=>get_the_title() )); echo"<br>";
                    echo get_the_title().'</a></div> ';
                echo '</ul>';




$NewSimpleRandomPosts = new SimpleRandomPosts();

function SimpleRandomPosts_widgets_init()

add_action('widgets_init', 'SimpleRandomPosts_widgets_init');

WordPress theming access for designers

Ever encoutered the following issue:  you want to give theming access to your worpdress designer, but cannot communicate the FTP account ? you have two solutions : first is to build specific FTP access for the theme directory you're working on. Second solution comes from DIY DESIGN, a theming company who have implemented a backup, upload, download for their custom themes, that for this particular usage they call skins, via the thesis skin manager introduced in their newest version of the thesis framework theme..

Magazine layout for wordpress : latest article for each category

a quick and efficient way of ensuring you have a permanent display of various articles on the front page of your wordpress blog is to alter the main query to get only one article per category. this can be done using specific join filters, as described on this wordpress support blog discussion. a very simple solution consists of including the alter-query.php file before the main query is executed. Here is the content of this file :

if (is_home())



function recent_join ( $join, $query ) {

global $wpdb;

$taxonomy = 'category';

$join .=<<<SQL

JOIN( SELECT MAX( {$wpdb->posts}.post_date ) AS post_date, trm.term_id AS term_ID FROM {$wpdb->posts}

LEFT JOIN {$wpdb->term_relationships} AS rel ON {$wpdb->posts}.ID=rel.object_ID

LEFT JOIN {$wpdb->term_taxonomy} AS tax USING( term_taxonomy_id )

LEFT JOIN {$wpdb->terms} AS trm USING( term_id )

WHERE tax.taxonomy='{$taxonomy}' GROUP BY trm.term_id ) AS pmx USING( post_date )


return $join;


add_filter ( 'posts_join', 'recent_join', 10, 2 );


function recent_fields ( $fields, $query ) {

global $wpdb;

return $fields . ', term_ID';


add_filter ( 'posts_fields', 'recent_fields', 10, 2 );


$args = array (

'post_type' => 'post',

'taxonomy' => 'category',

'paged' => get_query_var ( 'paged' ) ? get_query_var ( 'paged' ) : 1



wordpress post / page save and see

After a few hours of searching on the internet I finally assembled the hooks and actions necessary to add a new button to the save meta box for worpdress posts and pages. What I needed was a button that saves my work on a post edit page, and redirects to view the post .  here is the code for your functions.php file or plugin, change title in both functions for your own language preference. Hey who's making the plugin ?


add_action('post_submitbox_misc_actions', 'save_and_see_button');
function save_and_see_button()
    //global $post;
    echo '<div id="send-for-correction" class="misc-pub-section"
    style="border-top-style:solid; border-top-width:1px; border-top-color:#EEEEEE; border-bottom-width:0px;">
    <input id="save-post2" class="button button-highlighted"
    type="submit" value="MAJ + voir" name="save">
}add_filter( 'redirect_post_location' , 'my_filter_handler'   );
function my_filter_handler( $location  )
    global $post;
    if (  ($_POST['save'])== "MAJ + voir" &&  preg_match("/post=([0-9]*)/", $location, $match) &&
        $post &&
        $post->ID == $match[1] &&
        (isset($_POST['publish']) || $post->post_status == 'publish') && // Publishing draft or updating published post
        $pl = get_permalink($post->ID)
    ) {
        // Always redirect to the post
        $location = $pl;

     return $location;

Theme of the year : modernize by good layers

It's a rare occurence that I find a perfect wordpress theme that fits more than a single project : Modernize, sold by goodlayers  on themeforest, is one exceptionnal piece of code that does not just deal with front end layout : a powerful administration panel comes within the page / article administration system to help you configure complex layouts. Compatible not only with Internet Explorer (except old IE6), it also provides very efficient smartphone responsivness, and offers many more than just page management : slider integration, ajax portfolio management, testimonials, price table plus a great diversity of shortcodes that even your customer can use if they're familiar with wordpress system... Big thank you for support that answers quickly and correctly when you encounter customization issues, small drawback is the complexity of stylesheets and a few hours work to get your site up to speed by removing extra stylesheet and javascript goodies that you might not need. Good work Good Layers! 

Analytics in your dashboard plugin comparison

I've been using an old plugin that hasn't been updated in ages, and for a new customer I need to display serious analytics in my wordpress dashboard. I've tried a few but they don't work straight out of the box, ask you for you login and password, which I don't lie.


Thank mail chiomp guys, who are running the famous newsletter programm mailchimp, I have a serious plugin to integrate analytics in my dashboard. it only asks you permission to acccess analytics application via google permission, that you can revoke easily from your google account. 

links : 



wordpress search by attachment title

Funny enough, there many search enhancement plugins for wordpress, but It seems none of them can do what I want : return posts if one its child attachments matches the search query. It's easy enough when you think about it but the code below will save you the hour I spent looking for it on google .

add_filter('posts_join', 'po_search_join' );
add_filter('posts_where', 'po_search_where' );
add_filter('posts_groupby', 'po_search_groupby' );

function po_search_join( $join )
  global  $wpdb, $wp_query;
  if($wp_query->is_search  ) {
    $join .= " left JOIN {$wpdb->prefix}posts p2  ON  {$wpdb->prefix}posts.ID = p2.post_parent  "   ;

  return $join;

function po_search_where( $where )
{ global  $wpdb, $wp_query;    
  if($wp_query->is_search    ) {
    $where = $where . " or (p2.post_title LIKE '%" . addslashes_gpc($s)  . "%'
    ) ";
  return $where;

function po_search_groupby( $groupby )
  global  $wpdb, $wp_query;  

  if( !$wp_query->is_search ) {     return $groupby; }

  // we need to group on post ID
  $mygroupby = "{$wpdb->posts}.ID";

  if( preg_match( "/$mygroupby/", $groupby )) {
    // grouping we need is already there
    return $groupby;

  if( !strlen(trim($groupby))) {
    // groupby was empty, use ours
    return $mygroupby;

  // wasn't empty, append ours
  return $groupby . ", " . $mygroupby;

wordpress multilingual in widgets

I've a small issue with custom PHP code in html widgets combined to WPML because apparently widget code does not seem to be interpreted by WPML, probably a cause of hook orders. Here's how I made a widget display rencet posts depending on  chosen language:


WordPress : Combine Jquery slider and iphone touch swipe

in the process of building responsive themes, a challenge that's getting easier every day, you might encounter the need to satisfy your customer with touch reactivity : we describe here how to combine a nice and light slider plugin we donated 5$ to, bxslider, and the now famous jquery touchswipe plugin that brings touch reactivity to your web page if you look at it on your iphone, ipad, or any touch screen device . We have built a plugin and a custom code for gallery post format, specifically for wordpress default theme twentyeleven.


  • the plugin : bxslider , very easy : 
    • create the plugins/bxslider directory, and a bxslider.php file that contain
      Plugin Name: POLEOUEST-bxslider
      Author: erwan
      Version: 0.3
      Author URI: http://poleouest.Com/
      function my_init() {
          if (!is_admin()) {
            wp_enqueue_script('touchswipe', plugins_url('js/jquery.touchSwipe-1.2.5.js',__FILE__));       
            wp_enqueue_script('bsxslider', plugins_url('js/jquery.bxSlider.min.js',__FILE__));
           wp_enqueue_script('bsxslider', plugins_url('js/jquery.easing.1.3.js',__FILE__));     
      add_action('init', 'my_init');



    • put the appropriate javascript files in the js directory
  • the gallery post format code (loop code
                <div id="slider1"  >
    					$images = get_children( array( 'post_parent' => $post->ID, 'post_type' => 'attachment', 'post_mime_type' => 'image', 'orderby' => 'menu_order', 'order' => 'ASC', 'numberposts' => 999 ) );
    					if ( $images ) {
    						$total_images = count( $images );
    						foreach ($images as $image)
                                $image_img_tag = wp_get_attachment_image( $image->ID, 'large' );
    				<div>	 <?php echo $image_img_tag; ?></div>
    				 <!-- .gallery-thumb -->
                                           <?php }?>
                var slider="";
          slider =jQuery('#slider1').bxSlider({auto:true});   
         jQuery('#slider1').swipe( {swipeLeft:swipeLeft, swipeRight:swipeRight,threshold:0} ); 
       function swipeLeft(event){slider.goToNextSlide();}            
       function swipeRight(event){slider.goToPreviousSlide();     }        
               <?php          } ?>



and there you go.


wordpress : Custom fields for taxonomies

Taxonomies are interesting in term of data management, but in the basic wordpress installation, you are allowed very few field for content management. I needed extra fields to display tag specific content on the archive page, and first I tried the Ultimate Taxonomy Manager, which allows you to define custom post type taxonomies and  taxonomy specific custom field, with major drawbacks though

  • being taxonomy specific, you cannot define a global keyword content structure for all taxonomies at once. Furthermore, you have to define taxonomy specific  custom field names, which makes generic keyword theming harder.
  • being wholy interface based, the custom field definition cannot be coded and as such is a long task

I then did a new search and found a piece of code that allows to define custom field for taxonomies, allowing same naming and content structure for all taxonomies. Everything is based on code that you include in your theme function or in a plugin, and as such can be duplicated on new websites. It also comes with major interesting features such as wysiwyg field editor, and group field repeater which allows to define unlimited amount of group of custom field. The stuff is called WordPress Taxonomies extra field and as it says it comes the easy way! You might watch for a few bugs / things to improve :

  • custom taxonomy content is stored in wordpress option table, not the best for efficiency
  • wysiwyg field works fine but does some filtering on images and paragraphs... to follow
Another plugin works fine too, does not have wywiyg option but has the advantage of using a specific table for storing taxonomy content, which seems a safer choice than using the options table : http://wordpress.org/extend/plugins/categorycustomfields/