Home > CSS, Javascript, PHP > Testing code

Testing code

March 11th, 2009

Well, I’ve tried the codehighlighter plugin, the syntaxhighlighter plugin, and have just loaded the wp-codebox plugin. Other than a few CSS problems to work out, this one looks like the best.

Some CSS

?Download css.txt
1
2
3
4
5
6
blockquote {
background:#F4F5F7;
border:1px dashed #CCC;
padding:8px 12px 8px 36px;
margin:5px 0;
}

Some Javascript

1
2
3
4
5
this.REclassMain = new RegExp('\b' + this.classMain + '\b', 'gi');
this.REclassMainLive = new RegExp('\b' + this.classMainLive + '\b', 'gi');
this.REclassTab = new RegExp('\b' + this.classTab + '\b', 'gi');
this.REclassTabDefault = new RegExp('\b' + this.classTabDefault + '\b', 'gi');
this.REclassTabHide = new RegExp('\b' + this.classTabHide + '\b', 'gi');

Some PHP

?Download php.txt
1
2
3
4
5
6
<?php
$variable = wp_list_categories('echo=0&show_count=1&title_li=');	
$variable = str_replace(array('('), '<small>', $variable);
$variable = str_replace(array(')'), '  posts</small>', $variable);
echo $variable;
?>

CSS, Javascript, PHP

  1. J
    March 11th, 2009 at 12:19 | #1

    Well after a bit of editing, I think it’s looking pretty sweet.

  1. No trackbacks yet.