get_results("SELECT comment_count, ID, post_status, post_title FROM $wpdb->posts ORDER BY comment_count DESC LIMIT 0 , $num");
foreach ($posts as $post) {
setup_postdata($post);
$id = $post->ID;
$title = $post->post_title;
$count = $post->comment_count;
if ($count != 0 && $post->post_status == "publish") {
$popular .= '
'));
// Styling Tag Cloud
function style_tag_cloud($tags)
{
$tags = preg_replace_callback("|(class='tag-link-[0-9]+)('.*?)(style='font-size: )([0-9]+)(pt;')|",
create_function(
'$match',
'$low=1; $high=5; $sz=($match[4]-8.0)/(22-8)*($high-$low)+$low; return "{$match[1]} tagsz-{$sz}{$match[2]}";'
),
$tags);
return $tags;
}
//Loading Theme Options Framework
$themename = "Blogified";
$shortname = "Blogified";
$options = array (
array( "type" => "open",
"title" => "Navigation Settings"
),
array( "name" => "Exclude Pages from Navigation",
"desc" => "Type in Page IDs you would like to exclude from menu (Seperated by comma).",
"id" => "pages_excl",
"type" => "text",
"std" => ""),
array( "name" => "Limit Pages",
"desc" => "Type in a number to limit the pages being displayed in the menu. Type 0 to show all the Pages. By default the number of pages is limited to 9",
"id" => "pages_limit",
"type" => "text",
"std" => ""),
array( "type" => "close"),
array( "type" => "open",
"title" => "Styling Settings"
),
array( "name" => "Choose a highlight Colour",
"desc" => "Click on the input field and choose a highlight colour, after choosing click on the button on the bottom right of the colour picker",
"id" => "colorpicker",
"type" => "text",
"std" => "#3b3b3b"),
array( "type" => "close"),
array( "type" => "open",
"title" => "Page Template Settings"
),
array( "name" => "Accordion Slider Category ID",
"desc" => "Choose a category ID that will be shown in the Accordion Slider. You can enable the Accordion Slider by choosing it as an Page template.",
"id" => "accordion_cat",
"type" => "text",
"std" => ""),
array( "name" => "3d Slider Category ID",
"desc" => "Choose the category ID you would like to display in the 3d Slider. Select multiple categories seperated by comma. You can enable the 3d Slider by choosing it as an Page template",
"id" => "threed_cat",
"type" => "text",
"std" => ""),
array( "name" => "3d Slider Number",
"desc" => "Decide how many Posts you would like to display as an maximum for the 3d Slideshow.",
"id" => "threed_posts",
"type" => "text",
"std" => ""),
array( "name" => "3d Slider Slicing Effect",
"desc" => "The 3d Slider can slice horizontally or vertically.",
"id" => "threed_slicing",
"options" => array("horizontal", "vertical"),
"type" => "selectnormal",
"std" => "horizontal"),
array( "name" => "3d Slider Sliding direction",
"desc" => "The 3d Slider can slide to the left, right, up, down",
"id" => "threed_direction",
"options" => array("left", "right", "up", "down"),
"type" => "selectnormal",
"std" => "right"),
array( "type" => "close"),
array( "type" => "open",
"title" => "Sidebar Settings"
),
array( "name" => "Show Tab Menu?",
"desc" => "Do you want to show the Tab-Menu in the Sidebar with Recent Comments, Archives, Popular Posts ect.?",
"id" => "tab_show",
"options" => array("yes", "no"),
"type" => "selectnormal",
"std" => ""),
array( "type" => "close"),
array( "type" => "open",
"title" => "Twitter Settings"
),
array( "name" => "Twitter Username",
"desc" => "Please add your Twitter Username here. It will be used for the Twitter Icon and the Twitter Widget.",
"id" => "twitter_username",
"type" => "text",
"std" => ""),
array( "name" => "Number of latest Tweets",
"desc" => "Please choose how many latest Tweets you would like to display in the Twitter Widget.",
"id" => "twitter_number",
"type" => "text",
"std" => ""),
array( "type" => "close"),
array( "type" => "open",
"title" => "Advertisting Settings"
),
array( "name" => "Ad Slot 1",
"desc" => "Insert your Banner link/image link here. You can even insert Google Adsense Code. To show this add use the following shortcode within a post/page: [ad slot=\"1\" align=\"left\"].",
"id" => "ad_slot_1",
"type" => "textarea",
"std" => ""),
array( "name" => "Ad Slot 2",
"desc" => "Insert your Banner link/image link here. You can even insert Google Adsense Code. To show this add use the following shortcode within a post/page: [ad slot=\"2\" align=\"left\"].",
"id" => "ad_slot_2",
"type" => "textarea",
"std" => ""),
array( "name" => "Ad Slot 3",
"desc" => "Insert your Banner link/image link here. You can even insert Google Adsense Code. To show this add use the following shortcode within a post/page: [ad slot=\"3\" align=\"left\"].",
"id" => "ad_slot_3",
"type" => "textarea",
"std" => ""),
array( "type" => "close")
);
// create the Options page on the admin side
function mytheme_add_admin() {
global $themename, $shortname, $options;
// Saving and Updating the options
if (!empty($_GET['page']) && $_GET['page'] == basename(__FILE__)) {
if (!empty($_REQUEST['action']) && 'save' == $_REQUEST['action']) {
$myOptions = array();
foreach ($options as $value) {
if (!empty($value['id'])) {
$myOptions[$value['id']]=$_REQUEST[ $value['id'] ];
}
}
update_option('myOptions', $myOptions);
if (!empty($value['id']) && isset($_REQUEST[ $value['id']])) {
update_option('myOptions', $myOptions);
} elseif(!empty($value['id'])) {
delete_option( $value['id'] );
}
header("Location: themes.php?page=functions.php&saved=true");
} else if(!empty($_REQUEST['action']) && 'reset' == $_REQUEST['action']) {
foreach ($options as $value) {
delete_option( $value['id'] );
}
header("Location: themes.php?page=functions.php&reset=true");
}
}
// Add Options page to the admin menu
add_theme_page($themename." Options", "$themename Options", 'edit_themes', basename(__FILE__), 'mytheme_admin');
}
function mytheme_admin() {
global $themename, $shortname, $options;
?>
Blogified
Dontators who donate at least $5 will receive a lifetime backlink from our Supporters Page.
(write an E-Mail with link and linktext to supporters@wp-themix.org if you have made an donation).
Blogified Options Page
'.$themename.' settings saved.
';
if ( !empty($_REQUEST['reset']) && $_REQUEST['reset'] ) echo '
'.$themename.' settings reset.
';
?>
Thumbnails not working - Please give write permission to Theme (blogified) Folder (755 or 777)
You cannot upload images because the folder "wp-content/themes/blogified/images/logos/ is not writeable please CHMOD this folder to 755 or 777
Custom Logo
Select your Logo to upload. Your Logo should not be higher than 130px. The width can be up to 600px. You can only upload PNG or GIF (Logo has to have transparent background).