public
Last active

  • Download Gist
gistfile1.txt
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
// Add button above editor if not editing content_block
function add_content_block_icon($context) {
$context .= '<style>
#add-content-block .wp-media-buttons-icon {
background: url(../wp-content/plugins/custom-post-widget/images/contentblock.png) no-repeat -7px -40px;
margin-right: 3px;
}
#add-content-block:hover .wp-media-buttons-icon {
background: url(../wp-content/plugins/custom-post-widget/images/contentblock.png) no-repeat -7px -8px;
}
#add-content-block {
padding-left: 0.4em;
float:left;
}
.add_media{float:left;}
</style>
<a id="add-content-block" class="button thickbox" title="' . __("Add Content Block", 'custom-post-widget') . '" href="' . CUSTOM_POST_WIDGET_URL . 'popup.php?type=add_content_block_popup&amp;TB_inline=true&amp;inlineId=content-block-form">
<span class="wp-media-buttons-icon"></span>' . __("Add Content Block", "custom-post-widget") . '</a>';
return $context;
}

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.