BlueQ page in your admin area.
*/
include(dirname(__FILE__).'/themetoolkit.php');
themetoolkit(
'BlueQ',
array(
'about' => 'About You {textarea|6|50} ## Enter your brief about text. This will appear on the sidebar.',
'asides' => 'Asides Category ## Assign your asides category name here. Leave it blank for no asides support.',
'tags_cats' => 'Tags and Cats {radio|tags|Tags|cats|Categories|tagscats|Both} ## Use UTW or WP Native tags, Categories, or both.',
'floatq' => 'Float the Q {radio|yes|Yes|no|No} ## Chose whether or not to show my Q in the upper-left corner.',
'extrastyle' => 'Custom Style {textarea|6|50} ## Enter any custom CSS style you\'d like added to your BlueQ installation. It will be added into the header of your blog. This of course is purely for convienence. If you\'re comfortable editing CSS from style.css, then go right ahead.',
'keywords' => 'Meta Keywords {textarea|3|50} ## Meta keywords are a big deal. Just ask any SEO expert, they\'ll tell you the same. Enter the Meta keywords separated by commas you\'d like to insert into the header. This way its done easily without having to edit the theme directly or use a Meta keyword plugin.',
),
__FILE__
);
/***************************************
* Additional BlueQ Features and Functions
**************************************/
/* Short About blurb in sidebar */
function about() {
global $BlueQ;
$AboutTxt = $BlueQ->option['about'];
if (!$AboutTxt == '') {
print '
Author
';
print '' . $AboutTxt . '
';
}
}
/* Built-in Asides support */
function asides_hack($str) { return preg_replace('|s*|', '', $str); }
function use_asides() {
global $BlueQ;
$categories = array ();
foreach((get_the_category()) as $cat) {
$categories[] = $cat->cat_name;
}
if (in_array($BlueQ->option['asides'],$categories)) {
return true;
} else {
return false;
}
}
/* Float the BlueQ */
function floatimg() {
global $BlueQ;
$show_floatimg = $BlueQ->option['floatq'];
if ( $show_floatimg == "yes" ) {
print "";
}
}
/* Keywords added from BlueQ theme page. */
function blueq_keywords() {
global $BlueQ;
$bq_keywords = $BlueQ->option['keywords'];
if (!$bq_keywords == '') {
print "\n";
}
}
add_action('wp_head', 'blueq_keywords');
/* Extra CSS Style added from BlueQ theme page. */
function blueq_extrastyle() {
global $BlueQ;
$bq_extrastyle = $BlueQ->option['extrastyle'];
if (!$bq_extrastyle == '') {
print "\n";
}
}
add_action('wp_head', 'blueq_extrastyle');
/* Version of BlueQ */
function blueq_version() {
$blueq_ver = "1.0.1";
print $blueq_ver;
}
/* Show my credit in the footer */
function show_blueq_credit() { ?>
BlueQ Theme v
by Travis Quinnelly.
Tagged with:
' and %taglink%', 'first'=>' %taglink%')); ?>
Categories:
option['tags_cats'];
if ( $blueq_tags_cats == "tags" ) blueq_tags();
if ( $blueq_tags_cats == "cats" ) blueq_cats();
if ( $blueq_tags_cats == "tagscats" ) { blueq_tags(); blueq_cats(); }
}
/* Set default values upon theme install. */
if (!$BlueQ->is_installed()) {
$set_defaults['asides'] = '';
$set_defaults['about'] = "I haven't written anything about myself yet. Maybe I'll do that soon.";
$set_defaults['floatq'] = 'yes';
$set_defautls['extrastyle'] = '';
$set_defaults['keywords'] = 'BlueQ,';
$set_defaults['tags_cats'] = 'cats';
$result = $BlueQ->store_options($set_defaults);
}
/* Count Akismet Spam */
function blueq_spam_count() {
global $spamcount;
$spamcount = $spamcount + number_format(get_option('akismet_spam_count'));
echo $spamcount;
}
/* Widget Sidebar */
if ( function_exists('register_sidebar') )
register_sidebar(array (
'before_widget' => '',
'after_widget' => '',
'before_title' => '',
'after_title' => '
',
));
?>