Online tools to Minify and UnMinify JavaScripts

Minify/Compress JavaScripts

UnMinify/Decompress JavaScripts

Advertisements

Deploying WordPress as CMS

Here is the must read blog posts, for getting started with the Deployment of WordPress as CMS.

List of plugins, which I found very useful during my recent experience on deploying WordPress as CMS system

Active Directory Integration
http://wordpress.org/extend/plugins/active-directory-integration/

This plugin allows WordPress to authenticate, authorize, create and update users through Active Directory.

CMS Tree Page View
http://wordpress.org/extend/plugins/cms-tree-page-view/

Adds a CMS-like tree view of all your pages, like the view often found in a page-focused CMS. Use the tree view to edit, view, add pages and search pages (very useful if you have many pages). And with drag and drop you can rearrange the order of your pages. Page management won’t get any easier than this!

TagPages
http://wordpress.org/extend/plugins/tagpages/installation/

Adds post-tags functionality for pages.

ThreeWP Activity Monitor
http://wordpress.org/extend/plugins/threewp-activity-monitor/

Plugin to track user activity. Network aware. Track and display site or network-wide user activity.
Displays a multitude of user actions to keep the site administrator informed that all is well and that the blog or network is not being abused.

Table of Contents Creator (TOCC)
http://wordpress.org/extend/plugins/table-of-contents-creator/

Table of Contents Creator automatically generates a highly customizable dynamic site wide table of contents that is always up-to-date.  All entries are navigable making your site very SEO friendly. This plugin can be configured to display static pages, blog entries and forum comments. Another great feature of TOCC is the ability to include anchor tags on any page marked with a special class. This feature also allows links to articles, downloads or even other sites to appear within the table of contents as if they are part of your site’s navigation.|

TinyMCE Advanced
http://wordpress.org/extend/plugins/tinymce-advanced/

WordPress WYSIWYG editor

BackUpWordPress
http://wordpress.org/extend/plugins/backupwordpress/

Simple automated backups of your WordPress powered website. BackUpWordPress will back up your entire site including your database and all your files once every day.

WP Maintenance Mode
http://wordpress.org/extend/plugins/wp-maintenance-mode/

Adds a splash page to your site that lets visitors know your site is down for maintenance. Full access to the back- & front-end is optional. Works.

My favorite theme, which utilizes full browser width, and provides me a very pleasant experience when working on a large screen monitor.

Fluid Blue 1.7.2
http://wordpress.org/extend/themes/fluid-blue

Improved FTP backup for WordPress (Site Content + MySQL Database).

http://www.guyrutenberg.com/2010/02/28/improved-ftp-backup-for-wordpress/

Here is my modified version which allows, multiple backups a day. added hours-minute-second to the filenames. This script uses lftp, http://en.wikipedia.org/wiki/Lftp , a command line file transfer program for UNIX.

Script can be easily added to the crontab for automatic backup on remote FTP server.

#!/bin/bash
#
# Easily backup wordpress instances via ftp.
#

BACKUP_DIR="/root/localbackup/"
FTP_HOST="10.0.0.6"
FTP_USER="ftpusername"
FTP_PASS="ftppassword"
FTP_BACKUP_DIR="ftpdir/remotebackup"

BLOG_DIR="/var/www/html/mysite"

# end of configuration - you probably don't need to touch anything bellow

DB_NAME=`echo "<?php require_once(\"${BLOG_DIR}/wp-config.php\"); echo DB_NAME;" | php`<br ?>DB_USER=`echo "<?php require_once(\"${BLOG_DIR}/wp-config.php\"); echo DB_USER;" | php`<br ?>DB_PASS=`echo "<?php require_once(\"${BLOG_DIR}/wp-config.php\"); echo DB_PASSWORD;" | php`<br ?>DB_HOST=`echo " ${BACKUP_DIR}/${DUMP_NAME}
if [ "$?" -ne "0" ]; then
        echo "failed!"
        exit 1
fi
echo "done"

echo -n "Creating tarball... "
TAR_NAME=${BLOG_DIR##*/}-$(date +%Y%m%d-%H%M%S).tar.bz2
tar -cjf ${BACKUP_DIR}/${TAR_NAME} --exclude cache ${BLOG_DIR}
if [ "$?" -ne "0" ]; then
        echo "failed!"
        exit 2
fi
echo "done"

echo -n "Uploading SQL dump and tarball to FTP... "
lftp -u ${FTP_USER},${FTP_PASS} ${FTP_HOST} <<EOF
cd "${FTP_BACKUP_DIR}"
put "${BACKUP_DIR}/${DUMP_NAME}"
put "${BACKUP_DIR}/${TAR_NAME}"

EOF
if [ "$?" -ne "0" ]; then
        echo "failed!"
        exit 3
fi
echo "done"

How to avoid editing collision with multiple authors working on the same page/post

WordPress provides safe-guard with the warning if it finds multiple authors working on the same page or post, but does not block the user from creating edit conflicts.

Read more about this safe-guard – http://en.support.wordpress.com/editing-collisions/

If you need to lock down the page/post to allow only single autor editing at a time, here is the code you need to modify in /wp-admin/post.php file.
Modify the switch($action). Under the case “edit’, check the edit lock on the page using “wp_check_post_lock( $post->ID )”
Function Reference: http://wpseek.com/wp_check_post_lock/

Following is the modified case ‘edit’ code block. (WordPress 3.3.1)

case 'edit':
        $editing = true;

        if ( empty( $post_id ) ) {
                wp_redirect( admin_url('post.php') );
                exit();
        }

        $p = $post_id;

        if ( empty($post->ID) )
                wp_die( __('You attempted to edit an item that doesn’t exist. Perhaps it was deleted?') );

        if ( !current_user_can($post_type_object->cap->edit_post, $post_id) )
                wp_die( __('You are not allowed to edit this item.') );

        if ( 'trash' == $post->post_status )
                wp_die( __('You can’t edit this item because it is in the Trash. Please restore it and try again.') );

        if ( null == $post_type_object )
                wp_die( __('Unknown post type.') );

        /////////////////////////////////////////////////////////////////////////////
        // Changed by: Divyen Patel - Ensure Lock Down Post/Page Edit for multiple users.
        if ( $last = wp_check_post_lock( $post->ID ) ) {
                wp_die( __('Someone else is working on this page. Please retry after some time.') );
        }
        /////////////////////////////////////////////////////////////////////////////

        $post_type = $post->post_type;
        if ( 'post' == $post_type ) {
                $parent_file = "edit.php";
                $submenu_file = "edit.php";
                $post_new_file = "post-new.php";
        } else {
                if ( isset( $post_type_object ) && $post_type_object->show_in_menu && $post_type_object->show_in_menu !== true )
                        $parent_file = $post_type_object->show_in_menu;
                else
                        $parent_file = "edit.php?post_type=$post_type";
                $submenu_file = "edit.php?post_type=$post_type";
                $post_new_file = "post-new.php?post_type=$post_type";
        }

        if ( $last = wp_check_post_lock( $post->ID ) ) {
                add_action('admin_notices', '_admin_notice_post_locked' );
        } else {
                $active_post_lock = wp_set_post_lock( $post->ID );
                wp_enqueue_script('autosave');
        }

        $title = $post_type_object->labels->edit_item;
        $post = get_post_to_edit($post_id);

        if ( post_type_supports($post_type, 'comments') ) {
                wp_enqueue_script('admin-comments');
                enqueue_comment_hotkeys_js();
        }

        include('./edit-form-advanced.php');

        break;

I am synced and up-to-date with free reliable Cloud Storage

Amazon Cloud Drive
Free space: 5 GB
https://www.amazon.com/clouddrive/learnmore
Ubuntu One
Free space: 5 GB
https://one.ubuntu.com/
DropBox
Free space: 5 GB
https://www.dropbox.com/home
Google Drive
Free space: 5 GB
https://drive.google.com/start
Microsoft SkyDrive
Free space: 7 GB (Now), I was fortunate to be able upgrade to 25 GB Free!
https://skydrive.live.com

Importing/Exporting OVA in vSphere using VMware OVF Command line Tool

VMware OVF tool is a command line utility that supports import and export of OVF packages to and from vSphere infrastructure.

Download Tool – http://communities.vmware.com/community/vmtn/server/vsphere/automationtools/ovf
Documentation – http://www.vmware.com/support/developer/ovf/

Exporting Virtual Machine to OVA file

C:\Program Files\VMware\VMware OVF Tool>ovftool.exe "vi://username:password@vCenterIP:443/DataCenter_Name/vm/Demo-W7-VM" "C:\VM-Backup\Demo-W7-VM.ova"

Importing OVA VM to vSphere

C:\Program Files\VMware\VMware OVF Tool>ovftool.exe "--datastore=datastore1" "--network=VM-Network" "C:\VM-Backup\Demo-W7-VM.ova" "vi://username:password@vCenterIP/DataCenter_Name/host/Cluster_Name/hostIP"

Deploying Cisco UCS Emulator on VMware ESXi

Cisco UCS Emulator is a great tool to show many features that Cisco Unified Computing System (UCS) offers. It also gives something to use to get familiar with the system as well as can be used for the demo.

Download UCS Emulator Version 2.0 GA from http://developer.cisco.com/web/unifiedcomputing/ucsemulatordownload

Download the 7zip open source archiver from http://www.7zip.org to unzip the compressed emulator file.

Extract 7z archive. It contains VMDK files that can be used to deploy Virtual Machine on VMware Workstation or Fusion, but to deploy it on ESXi, some additional steps required to process files with VMware vCenter Converter and then we can deploy it to vCenter directly.

Download and Install VMware vCenter Converter from http://www.vmware.com/products/converter/

Launch vCenter Converter and Click File -> New -> Convert Machine

Select “VMware Workstation or Other VMware virtual machine” as the source type and select UCSPE.vmx as virtual machine file to process for conversion.

You can click on “View Source Details” link to know the VM configuration and disks layout.

Close Source Details Dialog and Click Next to proceed with the selection of target destination type.

Select “VMware Infrastructure virtual machine” as the destination type and provide destination information for vCenter Server.

Click Next to Continue. Specify Destination VM name “UCSPE_V2”.

Select a destination cluster resource, datastore and Virtual machine Version “Version 7” for the new VM.

Set the ‘Conversion Options’ before hitting the Finish button. Configure the destination VM parameters as per your need. You can chose to set disk formats to “Thin” or “Thick”, adjust CPU/Memory allocation and set desired destination network.

  

Confirm selected options from the Summary and then click Finish. The Conversion job will then be processed and status can be watched within the Converter window.

When completed, the VM will appear in the vCenter inventory with the name and configuration specified above.

Go to vCenter and Power-on the VM.

VM is pre-configured to obtain DHCP IP address. Once the VM is booted, it will show the UCS Web UI location and login details on the console.

 

Default admin password is the cisco for the UCS manager console.