Skip to content

Instantly share code, notes, and snippets.

@yihui
yihui / brush-loader.html
Created February 11, 2012 22:53
SyntaxHighlighter Brush for the R Language
<script type="text/javascript">
SyntaxHighlighter.autoloader(
"r  path/to/your/syntaxhighlighter/scripts/shBrushR.js",
"plain  path/to/your/syntaxhighlighter/scripts/shBrushPlain.js",
"sql  path/to/your/syntaxhighlighter/scripts/shBrushSql.js",
"js  path/to/your/syntaxhighlighter/scripts/shBrushJScript.js",
"html xml  path/to/your/syntaxhighlighter/scripts/shBrushXml.js"
);
SyntaxHighlighter.defaults["toolbar"] = false;
SyntaxHighlighter.all();
@dvdsmpsn
dvdsmpsn / menu-hover-click.confluence4.snippet.html
Last active August 23, 2021 02:40
How to open Atlassian Confluence drop down menus on mouse over rather than mouse click events
<!-- For Confluence 4.x -->
<script>
AJS.toInit(function($){
$('.ajs-menu-bar > li.ajs-menu-item').hover(
function(){
$(this).children('a')[0].click();
},
function(){
$(this).children('a')[0].click();
$(this).removeClass('hover');