10 super useful WordPress shortcodes

Display a snapshot of any website

Want to be able to take a snapshot of any website, and display it on your blog? This cool shortcode allows you to do so. Just paste the following code into your functions.php file:

function wpr_snap($atts, $content = null) {
        extract(shortcode_atts(array(
			"snap" => 'http://s.wordpress.com/mshots/v1/',
			"url" => 'http://www.catswhocode.com',
			"alt" => 'My image',
			"w" => '400', // width
			"h" => '300' // height
        ), $atts));

	$img = '<img src="' . $snap . '' . urlencode($url) . '?w=' . $w . '&h=' . $h . '" alt="' . $alt . '"/>';
        return $img;
}

add_shortcode("snap", "wpr_snap");

Once done, you can use the snap shortcode, as shown in the following example. It will display a CatsWhoCode.com snapshot on your own blog!

[snap url="http://www.catswhocode.com" alt="My description" w="400" h="300"]

Source: http://www.geekeries.fr/snippet/creer-automatiquement-miniatures-sites-wordpress/

Add a Paypal donation link easily

Many bloggers are asking support from their readers in the form of a Paypal donation. The following code creates a shortcode which will display a Paypal “donate” button on your site. Just paste the code below into your functions.php file:

function cwc_donate_shortcode( $atts ) {
    extract(shortcode_atts(array(
        'text' => 'Make a donation',
        'account' => 'REPLACE ME',
        'for' => '',
    ), $atts));

    global $post;

    if (!$for) $for = str_replace(" ","+",$post->post_title);

    return '<a class="donateLink" href="https://www.paypal.com/cgi-bin/webscr?cmd=_xclick&business='.$account.'&item_name=Donation+for+'.$for.'">'.$text.'</a>';

}
add_shortcode('donate', 'cwc_donate_shortcode');

Source: http://blue-anvil.com/archives/8-fun-useful-shortcode-functions-for-wordpress/

Obfuscate email addresses

As most of you know, spam bots are constantly scanning the internet in order to find emails to spam. Of course, you don’t want to receive spam, but what if you need to display your email (or someone else) on your blog? This code will create a shortcode which will obfuscate email adresses. As usual, let’s start by creating the shortcode: paste the code into your functions.php file.

function cwc_mail_shortcode( $atts , $content=null ) {
    for ($i = 0; $i < strlen($content); $i++) $encodedmail .= "&#" . ord($content[$i]) . ';';
    return '<a href="mailto:'.$encodedmail.'">'.$encodedmail.'</a>';
}
add_shortcode('mailto', 'cwc_mail_shortcode');

Then you can use the shortcode, which is pretty easy:

[mailto][email protected][/mailto]

Source: http://blue-anvil.com/archives/8-fun-useful-shortcode-functions-for-wordpress/

Create private content

If you want to create some private content that only registered users are able to see, the following shortcode is the solution to your problem. Paste the code below into your functions.php file in order to create the shortcode:

function cwc_member_check_shortcode( $atts, $content = null ) {
	 if ( is_user_logged_in() && !is_null( $content ) && !is_feed() )
		return $content;
	return '';
}

add_shortcode( 'member', 'cwc_member_check_shortcode' );

Then, proceed as shown below to create some member-only content:

[member]This text will be only displayed to registered users.[/member]

Source: http://snipplr.com/view.php?codeview&id=46936

Embed a PDF in an iframe

This is definitely the easiest way to display a PDF file on your website: The PDF is loaded through Google docs and then displayed in an iframe, on your own site.
To use this shortcode, first paste the code below into your functions.php file:

function cwc_viewpdf($attr, $url) {
    return '<iframe src="http://docs.google.com/viewer?url=' . $url . '&embedded=true" style="width:' .$attr['width']. '; height:' .$attr['height']. ';" frameborder="0">Your browser should support iFrame to view this PDF document</iframe>';
}
add_shortcode('embedpdf', 'cwc_viewpdf');

Then, use the following syntax to display a PDF. As you can see, it is possible to define width and height, which means that this shortcode will fit great on your blog, nevermind its layout.

[embedpdf width="600px" height="500px"]http://infolab.stanford.edu/pub/papers/google.pdf[/embedpdf]

Source: http://snipplr.com/view.php?codeview&id=35682

“Feed only” content shortcode

This shortcode create some content that will only be displayed on your RSS feed. Quite good to display some RSS-only ads, or an important message for your feed readers. The function have to be pasted in your functions.php. What, you guessed that? ;)

function cwc_feedonly_shortcode( $atts, $content = null) {
	if (!is_feed()) return "";
	return $content;
}
add_shortcode('feedonly', 'cwc_feedonly_shortcode');

Then, you can use the shortcode as shown below:

[feedonly]Dear RSS readers, please visit <a href="http://yourwebsite.com">my website</a> and click on a few ads[/feedonly]

Source: http://kovshenin.com/archives/snippet-a-feed-only-shortcode-for-wordpress/

“Retweet” shortcode using Tweetmeme

Tweeter is definitely a great source of trafic for bloggers. This is why this “Retweet” shortcode can be very useful. Paste the following code in your functions.php file in order to create the shortcode:

function tweetmeme(){
	return '<div class="tweetmeme"><script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js"></script></div>';
}
add_shortcode('tweet', 'tweetmeme');

Once done, you can display the Tweetmeme “retweet” button anywhere on your posts. In WordPress editor, make sure you are in HTML mode and insert the following:

[tweet]

Source: http://www.wprecipes.com/wordpress-tip-create-a-tweetmeme-retweeet-shortcode

Display the last image attached to post

Instead of dealing with image url, a simple shortcode can retrieve and display the last image attached to post. Paste the code below into your functions.php file in order to create the shortcode:

function cwc_postimage($atts, $content = null) {
	extract(shortcode_atts(array(
		"size" => 'thumbnail',
		"float" => 'none'
	), $atts));
	$images =& get_children( 'post_type=attachment&post_mime_type=image&post_parent=' . get_the_id() );
	foreach( $images as $imageID => $imagePost )
	$fullimage = wp_get_attachment_image($imageID, $size, false);
	$imagedata = wp_get_attachment_image_src($imageID, $size, false);
	$width = ($imagedata[1]+2);
	$height = ($imagedata[2]+2);
	return '<div class="postimage" style="width: '.$width.'px; height: '.$height.'px; float: '.$float.';">'.$fullimage.'</div>';
}
add_shortcode("postimage", "cwc_postimage");

Once done, you can display the last image by using the shortcode:

[postimage]

Source: http://www.wprecipes.com/wordpress-shortcode-easily-display-the-last-image-attached-to-post

Embed Youtube videos

If you often post videos from Youtube on your blog, this shortcode will make you save a lot of time. Let’s start by creating it by pasting the code below into your functions.php file:

function cwc_youtube($atts) {
	extract(shortcode_atts(array(
		"value" => 'http://',
		"width" => '475',
		"height" => '350',
		"name"=> 'movie',
		"allowFullScreen" => 'true',
		"allowScriptAccess"=>'always',
	), $atts));
	return '<object style="height: '.$height.'px; width: '.$width.'px"><param name="'.$name.'" value="'.$value.'"><param name="allowFullScreen" value="'.$allowFullScreen.'"></param><param name="allowScriptAccess" value="'.$allowScriptAccess.'"></param><embed src="'.$value.'" type="application/x-shockwave-flash" allowfullscreen="'.$allowFullScreen.'" allowScriptAccess="'.$allowScriptAccess.'" width="'.$width.'" height="'.$height.'"></embed></object>';
}
add_shortcode("youtube", "cwc_youtube");

Using the shortcode is pretty easy:

[youtube value="http://www.youtube.com/watch?v=1aBSPn2P9bg"]

Source: http://wpsnipp.com/index.php/functions-php/display-youtube-video-with-embed-shortcode/

Embed a RSS feed

This shortcode allows you to embed any RSS feed on your blog posts. Definitely cool for showcasing other blogs on your site! Just paste the code below into your functions.php file:

include_once(ABSPATH.WPINC.'/rss.php');

function cwc_readRss($atts) {
    extract(shortcode_atts(array(
	"feed" => 'http://',
      "num" => '1',
    ), $atts));

    return wp_rss($feed, $num);
}

add_shortcode('rss', 'cwc_readRss');

Then, you can use the shortcode as shown below:

[rss feed="http://feeds.feedburner.com/catswhocode" num="5"]  

Source: http://coding.smashingmagazine.com/2009/02/02/mastering-wordpress-shortcodes/

Reduce spam on your WordPress blog by using .htaccess

Simply paste the following lines into your .htaccess file. This file is located at the root of your WordPress install.
Remember to always make a backup of your .htaccess file before editing it so, you’ll be able to restore it if something went wrong.

Don’t forget to replace yourdomainname on line 5 by your real domain name.

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_METHOD} POST
RewriteCond %{REQUEST_URI} .wp-comments-post\.php*
RewriteCond %{HTTP_REFERER} !.*yourdomainname.* [OR]
RewriteCond %{HTTP_USER_AGENT} ^$
RewriteRule (.*) ^http://%{REMOTE_ADDR}/$ [R=301,L]
</IfModule>

Once you saved your .htaccess file, spam bots will not be able to access your wp-comments-post.php file directly. This will significantly reduce the amount of spam received on your blog.

Thanks to AllGuru.net for the tip!

Looking for WordPress hosting? Try WP Web Host. Prices starts at $5/month and you can try it for free!

Reduce spam on your WordPress blog by using .htaccess

10 online tools to simplify HTML5 coding

Initializr


Starting anew HTML5-based website? Just visit Initializr to get started. Initializr will generate for you a clean customizable template based on Boilerplate with just what you need to start.
→ visit Initializr

HTML5demos


Want to know if Firefox supports HTML5 canvas? Or if Safari can run the HTML5 simple chat client? HTML5demos will let you know instantly which property can be used on a specific browser.
→ visit HTML5 Demos

HTML5 Tracker


Want to stay connected with HTML5? Stay in touch with the latest revisions by using this tracker.
→ visit HTML5 Tracker

HTML5 visual cheat sheet


Need to quickly find a tag or an attribute? Just have a look at this very cool cheat sheet, and you’re done! A must-have for all web developers.
→ visit HTML5 visual cheat sheet

Switch To HTML5


Switch To HTML5 is a basic but efficient template generator. If you’re starting a new project, you should definitely visit this website and get your free HTML5 website template!
→ visit Switch To HTML5

Cross browser HTML5 forms


Forms are indeed an important part of any website. HTML5 features calendars, colour swatches, sliding widgets, client side validation and even more great tools, but there’s a problem: Most browsers do not support all those features. But thanks to this webpage, you can learn how to easily create HTML5 forms which are perfectly cross-browser compliant.
→ visit Cross browser HTML5 forms

HTML5 Test


Is your browser ready for the HTML5 revolution? HTML5 Test will let you know. The website will get you a full report of video, audio, canvas, etc capabilities of the browser you’re currently using.
→ visit HTML5 Test

HTML5 Canvas cheat sheet


The canvas element is a very important and interesting part of HTML5 as it allow you to draw on the screen. Many new possibilities are up to you, and if you need any help with the canvas element, go get this cheat sheet right now.
→ visit HTML5 Canvas cheat sheet

Lime JS


LimeJS is a HTML5 game framework for building fast, native-experience games for all modern touchscreens and desktop browsers. Absolutely awesome, a must try!
→ visit Lime JS

HTML5 Reset


HTML5 Reset is a set of files (HTML, CSS, etc) designed to help you save time when starting new projects. Good news, a HTML5 blank WordPress theme is freely available as well!
→ visit HTML5 Reset

WordPress shortcode: Display a thumbnail of any website

The first step is to create the shortcode. To do so, simply paste the code below into your functions.php file.

function wpr_snap($atts, $content = null) {
        extract(shortcode_atts(array(
			"snap" => 'http://s.wordpress.com/mshots/v1/',
			"url" => 'http://www.catswhocode.com',
			"alt" => 'My image',
			"w" => '400', // width
			"h" => '300' // height
        ), $atts));

	$img = '<img src="' . $snap . '' . urlencode($url) . '?w=' . $w . '&h=' . $h . '" alt="' . $alt . '"/>';
        return $img;
}

add_shortcode("snap", "wpr_snap");

Once done, you can use the snap shortcode, as shown in the following example:

[snap url="http://www.catswhocode.com" alt="My description" w="400" h="300"]

This will display a snapshot of CatsWhoCode. Please note that the height parameter can be ommitted.

Thanks to Valentin Brandt for the cool tip!

Looking for WordPress hosting? Try WP Web Host. Prices starts at $5/month and you can try it for free!

WordPress shortcode: Display a thumbnail of any website

How to display your latest Google+ update on your WordPress blog

Simply paste the following code where you want to display your latest Google+ update. Don’t forget to put your Google+ ID on line 3.

<?php
	include_once(ABSPATH.WPINC.'/rss.php');
	$googleplus = fetch_feed("http://plusfeed.appspot.com/103329092193061943712"); // Replace 103329092193061943712 by your own ID
	echo '<a href="';
	echo $googleplus->items[0]['link']; echo '">';
	echo $googleplus->items[0]['summary'];
	echo '';
?>

Thanks to Valentin Brandt for the cool tip!

Looking for WordPress hosting? Try WP Web Host. Prices starts at $5/month and you can try it for free!

How to display your latest Google+ update on your WordPress blog

Mastering the HTML5 <audio> tag

Using <audio> to insert a sound file on your website

Here is the most basic use of the <audio> tag: On this example it loads a mp3 file and play it. Notice the autoplay attribute which is used to play the sound automatically. That said, you shouldn’t play sounds automatically on a website: this is extremely boring for visitors.

<audio src="sound.mp3" autoplay></audio>

Play sound in loop

Want to loop a sound? The loop attribute is here to help. But once again, you shouldn’t abuse autoplay and loop playing if you want to prevent people from prematurely leaving your website!

<audio src="sound.mp3" autoplay loop></audio>

Display browser controls

Instead of playing sounds automatically, which is definitely a bad practice, you should let the browser display some controls such as volume, and a play/pause button. This can be done easily, simply by adding the controls attribute to the tag.

<audio src="sound.mp3" controls></audio>

Multiple file formats

<audio> is supported by most modern browsers, but the problem is that different browsers do not support the same file format. Safari can play mp3s, but Firefox can’t and play .ogg files instead. But Safari can’t play .ogg files…
The solution to this problem is to use both formats, so visitors can hear your sound, whatever the browser they use.

<audio controls>
  <source src="sound.ogg">
  <source src="sound.mp3">
</audio>

Specify MIME types

When using different file formats, it is a good practice to specify the MIME type of each file in order to help browser to localize the file they support. It can be done easily, using the type attribute.

<audio controls>
  <source src="sound.ogg" type="audio/ogg" >
  <source src="sound.mp3" type="audio/mp3" >
</audio>

Fallback for old browsers

And what if the visitor still use IE6, or another prehistoric browser with no support for the <audio> tag? A fallback can be easily implemented: As shown below, a message will be displayed to browsers who do not supports the <audio> tag.

<audio controls>
  <source src="sound.ogg" type="audio/ogg" >
  <source src="sound.mp3" type="audio/mp3" >
  Your browser does not support the audio tag!
</audio>

Buffer files

When playing large files, it is indeed a good idea to buffer files. To do so, you can use the preload attribute. It accept 3 values: none (If you don’t want the file to be buffered), auto (If you want the browser to buffer the file, and metadata (To buffer only metadata when page loads).

<audio controls>
  <source src="sound.mp3" preload="auto" >
</audio>

Control HTML5 <audio> with JavaScript

Controling a HTML5 audio player with JavaScript is pretty easy. The following example (Taken from Jeremy Keith book HTML5 for WebDesigners) shows how you can buid an audio player with basic controls (Play, Pause, Volume Up, Volume Down) using HTML and JavaScript.

<audio id="player" src="sound.mp3"></audio>
<div>
	<button onclick="document.getElementById('player').play()">Play</button>
	<button onclick="document.getElementById('player').pause()">Pause</button>
	<button onclick="document.getElementById('player').volume+=0.1">Volume Up</button>
	<button onclick="document.getElementById('player').volume-=0.1">Volume Down</button>
</div>

That’s all for today. I hope this article helped you to understand what you can do with the HTML5 <audio> tag. Any questions? Feel free to leave a comment below!

Easily remove weird characters from your WordPress database

Simply run the following SQL query on your WordPress database, using the command line client or PhpMyAdmin. This will remove weird characters from all your posts and comments.
Don’t forget to backup your database before using this query.

UPDATE wp_posts SET post_content = REPLACE(post_content, '“', '“');
UPDATE wp_posts SET post_content = REPLACE(post_content, '”', '”');
UPDATE wp_posts SET post_content = REPLACE(post_content, '’', '’');
UPDATE wp_posts SET post_content = REPLACE(post_content, '‘', '‘');
UPDATE wp_posts SET post_content = REPLACE(post_content, '—', '–');
UPDATE wp_posts SET post_content = REPLACE(post_content, '–', '—');
UPDATE wp_posts SET post_content = REPLACE(post_content, '•', '-');
UPDATE wp_posts SET post_content = REPLACE(post_content, '…', '…');

UPDATE wp_comments SET comment_content = REPLACE(comment_content, '“', '“');
UPDATE wp_comments SET comment_content = REPLACE(comment_content, '”', '”');
UPDATE wp_comments SET comment_content = REPLACE(comment_content, '’', '’');
UPDATE wp_comments SET comment_content = REPLACE(comment_content, '‘', '‘');
UPDATE wp_comments SET comment_content = REPLACE(comment_content, '—', '–');
UPDATE wp_comments SET comment_content = REPLACE(comment_content, '–', '—');
UPDATE wp_comments SET comment_content = REPLACE(comment_content, '•', '-');
UPDATE wp_comments SET comment_content = REPLACE(comment_content, '…', '…');

If you like to know more about WordPress SQL queries, you should have a look to this article.

Thanks to Jeff Starr for the cool tip!

Looking for WordPress hosting? Try WP Web Host. Prices starts at $5/month and you can try it for free!

Easily remove weird characters from your WordPress database

8 New and amazing WordPress hacks

Easily replace WordPress editor font

Don’t like the default font used by WordPress editor? No problem, the following code will allow you to change it. Simply paste it to your theme functions.php file. You can define which font to use on line 5.

add_action( 'admin_head-post.php', 'cwc_fix_html_editor_font' );
add_action( 'admin_head-post-new.php', 'cwc_fix_html_editor_font' );

function cwc_fix_html_editor_font() { ?>

<style type="text/css">#editorcontainer #content, #wp_mce_fullscreen { font-family: Georgia, "Times New Roman", "Bitstream Charter", Times, serif; }</style>
<?php }

Source: http://devpress.com/blog/fixing-wordpress-3-2s-html-editor-font/

Quick and easy maintenance mode

Sometimes, you need to put your blog on hold while performing some maintenance. Many plugins are allowing you to do so, but here is a simpler solution: Just paste the following snippet into your functions.php file and save it. Your blog is now unavailable to anyone except administrators. Don’t forget to remove the code when you’re done with maintenance!

function cwc_maintenance_mode() {
    if ( !current_user_can( 'edit_themes' ) || !is_user_logged_in() ) {
        wp_die('Maintenance, please come back soon.');
    }
}
add_action('get_header', 'cwc_maintenance_mode');

Source: http://skyje.com/2011/05/wordpress-code-snippets/

Simpler login url

Would you like to be able to use a simpler url like http://website.com/login to login to your WordPress dashboard? If yes, just read this recipe to learn how to implement it on your own blog.

Open your .htaccess file (located at the root of your WordPress install) and add the following code. Remember to backup your .htaccess file before editing it!

RewriteRule ^login$ http://yoursite.com/wp-login.php [NC,L]

Source: http://www.wprecipes.com/simpler-wordpress-login-url

Disable theme switching

When working with clients, it can be good to keep the control of what they can do to prevent possible problems. For example, disabling theme switching can be a good idea, especially if the site you built heavily rely on the theme. To do so, just paste the code below into the functions.php file of the theme. Once done, the client will not be able to switch themes anymore.

add_action('admin_init', 'cwc_lock_theme');
function cwc_lock_theme() {
	global $submenu, $userdata;
	get_currentuserinfo();
	if ($userdata->ID != 1) {
		unset($submenu['themes.php'][5]);
		unset($submenu['themes.php'][15]);
	}
}

Source: http://sltaylor.co.uk/blog/disabling-wordpress-plugin-deactivation-theme-changing/

Disable RSS feed

By default, WordPress include the popular RSS functionnality, which is great for blogs. But if you’re using your WordPress install as a static site, having RSS feeds may become a bit confusing for your visitors.

This code will totally disable RSS feeds (As well as other formats) from your blog. Just paste the code into functions.php, and you’re done.

function cwc_disable_feed() {
	wp_die( __('No feed available,please visit our <a href="'. get_bloginfo('url') .'">homepage</a>!') );
}
add_action('do_feed', 'cwc_disable_feed', 1);
add_action('do_feed_rdf', 'cwc_disable_feed', 1);
add_action('do_feed_rss', 'cwc_disable_feed', 1);
add_action('do_feed_rss2', 'cwc_disable_feed', 1);
add_action('do_feed_atom', 'cwc_disable_feed', 1);

Source: http://wpengineer.com/287/disable-wordpress-feed/

Filter custom post types by author in admin

Here is a function which adds a dropdown select control of users next to existing filters (by default, date). It also works in tandem with the built in author filtering which is available when you click on an author in on admin listing pages (by default on posts and pages).

As usual, the only thing you have to do to implement this code is to paste it into your functions.php file.

function cwc_restrict_manage_authors() {
        if (isset($_GET['post_type']) && post_type_exists($_GET['post_type']) && in_array(strtolower($_GET['post_type']), array('your_custom_post_types', 'here'))) {
                wp_dropdown_users(array(
                        'show_option_all'       => 'Show all Authors',
                        'show_option_none'      => false,
                        'name'                  => 'author',
                        'selected'              => !empty($_GET['author']) ? $_GET['author'] : 0,
                        'include_selected'      => false
                ));
        }
}
add_action('restrict_manage_posts', 'cwc_restrict_manage_authors');

Source: http://forrst.com/posts/WordPress_Custom_Post_Types_Filter_by_Author_in-s9p

Add post thumbnails to RSS feed

This very cool piece of code will get the post thumbnail and automatically add it to your RSS feeds. Paste the code into functions.php and save the file. Don’t forget that you need to use a theme that supports post thumbnails for this snippet to work.

function cwc_rss_post_thumbnail($content) {
    global $post;
    if(has_post_thumbnail($post->ID)) {
        $content = '<p>' . get_the_post_thumbnail($post->ID) .
        '</p>' . get_the_content();
    }

    return $content;
}
add_filter('the_excerpt_rss', 'cwc_rss_post_thumbnail');
add_filter('the_content_feed', 'cwc_rss_post_thumbnail');

Source: http://snipplr.com/view.php?codeview&id=56180

Remove WordPress admin bar

Introduced in WordPress 3.X, the new “Admin bar” is an useful feature, but if you don’t like it, you can easily remove it. Just paste the following snippet into your functions.php file.

add_filter('show_admin_bar', '__return_false');

Source: http://speckyboy.com/2011/03/01/how-to-remove-the-admin-bar-from-wordpress-3-1/

How to easily test if an entry is a custom post type

Simply paste the following function into your functions.php file:

function wpr_is_post_type($type){
    global $wp_query;
    if($type == get_post_type($wp_query-&gt;post-&gt;ID)) return true;
    return false;
}

Once done you can use the function in your themes:

if (wpr_is_post_type($type){
    ...
}

Thanks to John for submitting this cool function!

Looking for WordPress hosting? Try WP Web Host. Prices starts at $5/month and you can try it for free!

How to easily test if an entry is a custom post type

How to change WordPress editor font

Nothing complicated. Simply open your functions.php file and paste the following code:

add_action( 'admin_head-post.php', 'devpress_fix_html_editor_font' );
add_action( 'admin_head-post-new.php', 'devpress_fix_html_editor_font' );

function devpress_fix_html_editor_font() { ?>
<style type="text/css">#editorcontainer #content, #wp_mce_fullscreen { font-family: Georgia, "Times New Roman", "Bitstream Charter", Times, serif; }</style>
<?php }

Once you saved the file, the editor font is changed to Georgia. Of course, feel free to modify the code to display your favorite font.

Thanks to DevPress for the cool tip!

Looking for WordPress hosting? Try WP Web Host. Prices starts at $5/month and you can try it for free!

How to change WordPress editor font

10 super useful tools for JavaScript developers

MicroJS


Need a piece of code quickly? MicroJS is a brand new site which aim to provide JavaScript code snippet for most common tasks: Ajax, Json, DOM, Object-Oriented JavaScript, and more. A true gold mine to have in your bookmarks!
Visit http://microjs.com/

Diva.js


Diva is a Javascript frontend for viewing documents, designed to work with digital libraries to present multi-page documents as a single, continuous item. It is designed to work with a IIPImage server and will be an awesome tool for those working on library or bookstore websites. A demo is available here if you want to have a look.
Visit http://ddmal.music.mcgill.ca/diva/

Bookmarklet Generator


As you can guess, this tool is a bookmarklet generator: Simply paste your regular JavaScript code, press the button and you’ll get a bookmarklet – ready to be installed on your browser bar.
Visit http://benalman.com/code/test/jquery-run-code-bookmarklet/

jQAPI


Like any other jQuery developers, I spend a large amount of time digging in the documentation. jQAPI is a website which provides the jQuery documentation in a more user-friendly way, so it is now my reference site when I need any jQuery help.
Visit http://jqapi.com

heatmap.js


Day after day, JavaScript continues to surprise me with its endless possibilities: For example, heatmap.js allows you to generate web heatmaps with the html5canvas element based on your data. Easy and efficient!
Visit http://www.patrick-wied.at/static/heatmapjs/

Respond.js


Remember my article about adaptable layouts with CSS3 media queries? Respond.js is a small script that allow you to use CSS3 media queries on browsers that do not support it yet (Yes IE, we’re looking at you…).
Visit https://github.com/scottjehl/Respond/blob/master/respond.min.js

Modernizr


Modernizr is a script that helps older browsers to work almost as good as newest ones, so you can build modern applications that will work on IE6 and 7. Your clients will love it, that’s guaranteed.
Visit http://www.modernizr.com/

YepNope


YepNope aim is pretty simple: It answers yep, or nope. For example, ask YepNope is Modernizr is loaded. If yes, ask YepNope to do this, and if not, ask YepNope to do that. That’s simple as that, and very useful in many cases.
Visit http://yepnopejs.com/

Ligature.js


Ligature.js is, unsurprisingly, a script that adds pretty ligatures to any kind of text. A must-have for all typography lovers out here!
Visit http://code.google.com/p/ligature-js/

FitText.js


FitText is a very interesting tool, that allows the automatic resizing of a text regarding the size of its parent element. Just have a look to the website and resize your browser: The text will fit. Another very interesting tool for modern websites and applications!
Visit http://fittextjs.com/

10 super useful tools for JavaScript developers

MicroJS


Need a piece of code quickly? MicroJS is a brand new site which aim to provide JavaScript code snippet for most common tasks: Ajax, Json, DOM, Object-Oriented JavaScript, and more. A true gold mine to have in your bookmarks!
Visit http://microjs.com/

Diva.js


Diva is a Javascript frontend for viewing documents, designed to work with digital libraries to present multi-page documents as a single, continuous item. It is designed to work with a IIPImage server and will be an awesome tool for those working on library or bookstore websites. A demo is available here if you want to have a look.
Visit http://ddmal.music.mcgill.ca/diva/

Bookmarklet Generator


As you can guess, this tool is a bookmarklet generator: Simply paste your regular JavaScript code, press the button and you’ll get a bookmarklet – ready to be installed on your browser bar.
Visit http://benalman.com/code/test/jquery-run-code-bookmarklet/

jQAPI


Like any other jQuery developers, I spend a large amount of time digging in the documentation. jQAPI is a website which provides the jQuery documentation in a more user-friendly way, so it is now my reference site when I need any jQuery help.
Visit http://jqapi.com

heatmap.js


Day after day, JavaScript continues to surprise me with its endless possibilities: For example, heatmap.js allows you to generate web heatmaps with the html5canvas element based on your data. Easy and efficient!
Visit http://www.patrick-wied.at/static/heatmapjs/

Respond.js


Remember my article about adaptable layouts with CSS3 media queries? Respond.js is a small script that allow you to use CSS3 media queries on browsers that do not support it yet (Yes IE, we’re looking at you…).
Visit https://github.com/scottjehl/Respond/blob/master/respond.min.js

Modernizr


Modernizr is a script that helps older browsers to work almost as good as newest ones, so you can build modern applications that will work on IE6 and 7. Your clients will love it, that’s guaranteed.
Visit http://www.modernizr.com/

YepNope


YepNope aim is pretty simple: It answers yep, or nope. For example, ask YepNope is Modernizr is loaded. If yes, ask YepNope to do this, and if not, ask YepNope to do that. That’s simple as that, and very useful in many cases.
Visit http://yepnopejs.com/

Ligature.js


Ligature.js is, unsurprisingly, a script that adds pretty ligatures to any kind of text. A must-have for all typography lovers out here!
Visit http://code.google.com/p/ligature-js/

FitText.js


FitText is a very interesting tool, that allows the automatic resizing of a text regarding the size of its parent element. Just have a look to the website and resize your browser: The text will fit. Another very interesting tool for modern websites and applications!
Visit http://fittextjs.com/

10 super useful tools for JavaScript developers

MicroJS


Need a piece of code quickly? MicroJS is a brand new site which aim to provide JavaScript code snippet for most common tasks: Ajax, Json, DOM, Object-Oriented JavaScript, and more. A true gold mine to have in your bookmarks!
Visit http://microjs.com/

Diva.js


Diva is a Javascript frontend for viewing documents, designed to work with digital libraries to present multi-page documents as a single, continuous item. It is designed to work with a IIPImage server and will be an awesome tool for those working on library or bookstore websites. A demo is available here if you want to have a look.
Visit http://ddmal.music.mcgill.ca/diva/

Bookmarklet Generator


As you can guess, this tool is a bookmarklet generator: Simply paste your regular JavaScript code, press the button and you’ll get a bookmarklet – ready to be installed on your browser bar.
Visit http://benalman.com/code/test/jquery-run-code-bookmarklet/

jQAPI


Like any other jQuery developers, I spend a large amount of time digging in the documentation. jQAPI is a website which provides the jQuery documentation in a more user-friendly way, so it is now my reference site when I need any jQuery help.
Visit http://jqapi.com

heatmap.js


Day after day, JavaScript continues to surprise me with its endless possibilities: For example, heatmap.js allows you to generate web heatmaps with the html5canvas element based on your data. Easy and efficient!
Visit http://www.patrick-wied.at/static/heatmapjs/

Respond.js


Remember my article about adaptable layouts with CSS3 media queries? Respond.js is a small script that allow you to use CSS3 media queries on browsers that do not support it yet (Yes IE, we’re looking at you…).
Visit https://github.com/scottjehl/Respond/blob/master/respond.min.js

Modernizr


Modernizr is a script that helps older browsers to work almost as good as newest ones, so you can build modern applications that will work on IE6 and 7. Your clients will love it, that’s guaranteed.
Visit http://www.modernizr.com/

YepNope


YepNope aim is pretty simple: It answers yep, or nope. For example, ask YepNope is Modernizr is loaded. If yes, ask YepNope to do this, and if not, ask YepNope to do that. That’s simple as that, and very useful in many cases.
Visit http://yepnopejs.com/

Ligature.js


Ligature.js is, unsurprisingly, a script that adds pretty ligatures to any kind of text. A must-have for all typography lovers out here!
Visit http://code.google.com/p/ligature-js/

FitText.js


FitText is a very interesting tool, that allows the automatic resizing of a text regarding the size of its parent element. Just have a look to the website and resize your browser: The text will fit. Another very interesting tool for modern websites and applications!
Visit http://fittextjs.com/

10 super useful tools for JavaScript developers

MicroJS


Need a piece of code quickly? MicroJS is a brand new site which aim to provide JavaScript code snippet for most common tasks: Ajax, Json, DOM, Object-Oriented JavaScript, and more. A true gold mine to have in your bookmarks!
Visit http://microjs.com/

Diva.js


Diva is a Javascript frontend for viewing documents, designed to work with digital libraries to present multi-page documents as a single, continuous item. It is designed to work with a IIPImage server and will be an awesome tool for those working on library or bookstore websites. A demo is available here if you want to have a look.
Visit http://ddmal.music.mcgill.ca/diva/

Bookmarklet Generator


As you can guess, this tool is a bookmarklet generator: Simply paste your regular JavaScript code, press the button and you’ll get a bookmarklet – ready to be installed on your browser bar.
Visit http://benalman.com/code/test/jquery-run-code-bookmarklet/

jQAPI


Like any other jQuery developers, I spend a large amount of time digging in the documentation. jQAPI is a website which provides the jQuery documentation in a more user-friendly way, so it is now my reference site when I need any jQuery help.
Visit http://jqapi.com

heatmap.js


Day after day, JavaScript continues to surprise me with its endless possibilities: For example, heatmap.js allows you to generate web heatmaps with the html5canvas element based on your data. Easy and efficient!
Visit http://www.patrick-wied.at/static/heatmapjs/

Respond.js


Remember my article about adaptable layouts with CSS3 media queries? Respond.js is a small script that allow you to use CSS3 media queries on browsers that do not support it yet (Yes IE, we’re looking at you…).
Visit https://github.com/scottjehl/Respond/blob/master/respond.min.js

Modernizr


Modernizr is a script that helps older browsers to work almost as good as newest ones, so you can build modern applications that will work on IE6 and 7. Your clients will love it, that’s guaranteed.
Visit http://www.modernizr.com/

YepNope


YepNope aim is pretty simple: It answers yep, or nope. For example, ask YepNope is Modernizr is loaded. If yes, ask YepNope to do this, and if not, ask YepNope to do that. That’s simple as that, and very useful in many cases.
Visit http://yepnopejs.com/

Ligature.js


Ligature.js is, unsurprisingly, a script that adds pretty ligatures to any kind of text. A must-have for all typography lovers out here!
Visit http://code.google.com/p/ligature-js/

FitText.js


FitText is a very interesting tool, that allows the automatic resizing of a text regarding the size of its parent element. Just have a look to the website and resize your browser: The text will fit. Another very interesting tool for modern websites and applications!
Visit http://fittextjs.com/

How to remove the “read more” jump

Paste the following snippet into your functions.php file:

function wdc_no_more_jumping($post) {
     return '<a href="'.get_permalink($post->ID).'" class="read-more">'.'Continue Reading'.'</a>';
}
add_filter('excerpt_more', 'wdc_no_more_jumping');

Thanks to Alex Denning for the cool tip!

Looking for WordPress hosting? Try WP Web Host. Prices starts at $5/month and you can try it for free!

How to remove the “read more” jump