Today, services like Twitter impose the use of short URL, certainly in the network there are several free services, but if we want something we can use custom WordPress to create a dedicated service to our blog. The trick is to exploit the demand for each item, calling for his ID stored in the database.
In part we can put this piece of HTML code to display a link to “short”.
<?php echo get_bloginfo('url')."/?p=".$post->ID; ?>

