Styling the Syntax Highlighter

I am using the Syntax Highlighter Evolved by Alex Gorbatchev and for those of you who are curious, this is how I styled the code block.

I have added a border and change the font size to 16px so that it could better fit into the post.

.syntaxhighlighter {
	background-color: white !important;
	border: 1px solid #DADAD9 !important;
	margin-bottom: 20px !important;

body .syntaxhighlighter .code {
	font-size: 16px !important;

body .syntaxhighlighter .gutter {
	font-size: 16px !important;

Display a youtube link in WP post

This entry is part 1 of 2 in the series Wordpress

In a WordPress post, you might have a custom field which is a Youtube link and as this youtube link is just part of the content, you might want to display it directly in the post.

This is called embedded content and in WordPress, it provides a function called wp_oembed_get:

<?php $embed_code = wp_oembed_get( $url, $args );   ?>

To display this youtube video in the post, you can save this field in wp_postmeta table with the meta_key in the table as youtube_link.

The code is as shown below and you could put it at the end of functions.php found in the WordPress theme.