Call Now 407.243.8420

Posts Tagged ‘website design’

Display Top Posts in WordPress with Google Analytics

Thursday, March 24th, 2011

In today’s tutorial we show you one way of displaying a list of the most popular posts in your WordPress template or sidebar. To do this you must first set up your site to use Google Analytics and make sure you’ve placed the code snippet in your theme’s footer.php. Next install the “Google Analytics Dashboard” plugin which can be found here:

http://wordpress.org/extend/plugins/google-analytics-dashboard/

We tested this with version 2.0.3 of the Google Analytics Dashboard wordpress plugin.

<?php
	// options
	$showposts = 3; // how many posts/pages to display?
	$days = 30; // how many days back to calculate?
 
	// do not edit below this line
	$thispost = 1;
	$start = date('Y-m-d', (time() - (60 * 60 * 24 * $days)));
	$end = date('Y-m-d');
	$login = new GADWidgetData(get_option('gad_auth_token'), get_option('gad_account_id'));
	$ga = new GALib('client', $login->auth_token, '', '', $login->account_id);
	$pages = $ga->pages_for_date_period($start, $end);
	echo "<ul>";
	foreach($pages as $page) {
		$url = $page['value'];
		$title = $page['children']['value'];
		// ignore these page titles
		$ignore = array(
			'(not set)',
			'Page Title 1',
			'Page Title 2'
		);
		if(!in_array($title, $ignore)){
			// list any strings you would like to remove from the titles
			$remove = array(
				" | Company Name",
				" « Company Name"
			);
			$newtitle = str_replace($remove, "", $title);
			echo '<li><a href="' . $url . '" rel="nofollow">' . $newtitle . '</a></li>';
			$thispost++;
		}
		if($thispost > $showposts) break;
	}
	echo "</ul>";
?>

How to Improve your Web Design Skills

Wednesday, August 25th, 2010

Be sure and check out this great article on learning website design. Leave a comment and let us know what you think!

HTML E-mail Signatures in Thunderbird

Saturday, April 24th, 2010

In this tutorial we explore creating an HTML signature for your e-mail account. This tutorial explains creating and using a signature in Mozilla Thunderbird, but other e-mail clients should have similar functionality.
(more…)