Updates to the Zazz Post Ticker

If you are using WordPress 2.3.3 (the recent version) please hold off on installing the updated plugin as the category filter is reading from the wrong table

After about a dozen emails requesting that the Zazz Post Ticker should have a way to display posts only in certain categories, I’ve gone and done it. To get the new feature rigged up with your blog, download the updated plugin file here. Then, open up the plugin file and hook the $category_filters variable up to a list of categories you want the ticker to display. An example of values could be:

$category_filters = "4"; The above would display only posts from the category number 4

$category_filters = "1, 4, 7, 9, 10";The above would display posts from any of the listed categories

To find the numerical ID for your categories, login to your Wordpress admin panel and go to Manage > Categories. Each row will have the categories associated ID # in the first column.

For anyone who is happily using the plugin, I’d love to see your blog, so please comment this post with a link! Also post any questions or comments on this page and I’ll go through them as swiftly as possible.

jQuery is Amazing

I just wanted to make a quick post stating my infatuation with jQuery. I don’t know why it took me so long to give it a try, but I am extremely happy I did. It’s the perfect solution for fast , cross-browser compatible javascript programming. I’ve got it on every new site I’m developing. I just want to spread the word and hopefully enlighten any developers who haven’t tried it yet.

Surfing around Amazon, I came across this watch, and its possibly the nicest watch I’ve ever seen. To hold myself more accountable to actually buying it one day, I’m going to publish it in my blog. I may add more items to the wishlist once and a while, and of course, I will make a post when I actually buy something off the wishlist!

Omega Men's Aqua Terra Automatic Watch

Watch Information
Brand Name: Omega
Model number: 2503.80.00
dial_window_material_type: scratch-resistant-sapphire
Clasp: push-button-folding-clasp
Case material: stainless-steel
Band material: stainless-steel
Band length: mens-standard
Dial color: blue face
Bezel material: stainless-steel
Bezel Function: stationary
Calendar: Date
Movement: analog-quartz
Water resistant depth: 500 Feet

AOL Rips off Yahoo

Is it just me, or is the AOL homepage an exact replica of Yahoo’s Homepage? I remember reading up on a discrepancy between Google and Yahoo in Matt Cutts’ blog about Google ripping off one of Yahoo’s toolbar pages, but the entire homepage? C’mon.

Yahoo
yahoo homepage

AOL
aol homepage

Well then…

One thing I’ve always had trouble with in my time in business online, is paying for services I’m well capable of doing myself. In this case, the task was compiling a media kit for a large website that I own and operate. The media kit will be distributed to potential advertisers (big advertisers! like Nike, Puma, and McDonalds,) who can soak up a quick few informational paragraphs and demographics to scrutinize your website, and decide whether you’re worth their time. Nonetheless, I told myself, I know my website better than any hired writer every could; but alas, I could never squeeze out the needed information. I’d always write a paragraph, and then rewrite it, and then, delete it and start from scratch. It eventually gets put off, because of course, I do have a large website to run! Its been about 8 months since I took on the task of producing a media kit, and you guessed it, theres no media kit.

I’m letting the professionals move in. I’ve hired a professional copywriting service to write me the entire text for my media kit, for 350 bucks. Its in the works right now, so I can’t say if the service is any good, but it will be a learning experience nonetheless. At first I had a little trouble rationalizing the price, but then I remembered some figures I was told that I could easily make if I sold big advertising deals. What is 350 bucks now, if I can make 5 figures per campaign later?

How many times have you seen people trying to sneak affiliate links into their content, and even if you are extremely interested in the product that is being promoted, you don’t go through their affiliate link. Whatever the reason people who are tech savvy don’t follow blatant affiliate links may be out of envy or just straight up spite. Don’t fret, I’ve got a new trick for you. With the power of JavaScript, you can show people a clean, affiliate free link to a product or service, but when they actually click the link, you can send them to a completely different URL. This technique could potentially be used for very evil things, so I’m a tad reluctant to share this, but I’m crossing my fingers it will be used in good faith.

First, try out these examples.
Affiliate link, same window
Affiliate link, new window

Roll your cursor over them, check their properties, even go ahead and view the page source. These are hard links to Google.ca and Amazon.ca. However, go as far as clicking them and you will be in for a surprise. You are now at Yahoo.ca! What happened?!

JavaScript gives you the ability to prevent the default browser action from taking place. With this code in place, we can prevent the links from opening their href attribute, and instead tell them to do something complete different, in this case, launch a different link (the link with your affiliate code tacked on.) If you’re using a good affiliate, the site will quickly register your affiliate ID and the transition will be seamless to the affiliate product page. Lets take a look at the code in place..

<script type="text/javascript">
function goto(url, newWin)
{
	if (newWin) {
		var win2 = window.open(url, '_blank');
		win2.focus();
	}
	else {
		document.location.href = url;
	}
}
function stopDefault(e)
{
	e = (e) ? e : window.event;
	if (e.preventDefault) e.preventDefault();
	else e.returnValue = false;
}
window.onload = function()
{
	var link_1 = document.getElementById('link_1');
	link_1.onclick = function(event) { stopDefault(event); }
	link_1.onmouseup = function() { goto('http://www.yahoo.ca/', 0); }

	var link_2 = document.getElementById('link_2');
	link_2.onclick = function(event) { stopDefault(event); }
	link_2.onmouseup = function() { goto('http://www.yahoo.ca/', 1); }
}
</script>

Where you place the code won’t affect it. If you’re worried that the curious will view your source and read through for something elusive, you can just pack it into an external javascript file which will lose most users in their affiliate link sniffing endeavours. Nonetheless, lets go ahead and do a little code analysis:

<script type="text/javascript">
function goto(url, newWin)
{
	if (newWin) {
		var win2 = window.open(url, '_blank');
		win2.focus();
	}
	else {
		document.location.href = url;
	}
}
function stopDefault(e)
{
	e = (e) ? e : window.event;
	if (e.preventDefault) e.preventDefault();
	else e.returnValue = false;
}

These two functions do exactly what you’d expect them to do. The goto function tells the browser to navigate to your custom link, while stopDefault stops the browser from doing its default action, which would be navigation to the href attribute.

window.onload = function()
{
	var link_1 = document.getElementById('link_1');
	link_1.onclick = function(event) { stopDefault(event); }
	link_1.onmouseup = function() { goto('http://www.yahoo.ca/', 0); }

	var link_2 = document.getElementById('link_2');
	link_2.onclick = function(event) { stopDefault(event); }
	link_2.onmouseup = function() { goto('http://www.yahoo.ca/', 1); }
}

This snippet is executed when the window is done loading and applies the aforementioned functions to the links we want to add the elusive linking technique to. You have to sync these lines up with the id attribute of the links or you will receive a nasty javascript error message. As you can see I have given the links in the body the IDs “link_1″ and “link_2″.

<a href="http://www.google.ca/" id="link_1">Affiliate link, same window</a>
<a href="http://www.amazon.ca/" id="link_2">Affiliate link, new window</a>

Its not Perfect
Unfortunately, though this system is extremely elusive, it is not perfect. As a FireFox user, I often use the scroll button on the mouse to click links to quickly open them up in a new tab. When this happens, the browser executes the default action anyways AS WELL AS your custom script. This will load your custom link as well as the displayed link, which will most likely confuse the user.

In conclusion, with this code I’m hoping to help affiliate publishers jump over the hurdle of affiliate links poor performance because of a nasty and blatant referral code tacked on to the end of an address. If you are using a similar method to cloak your affiliate links, please share!

seo blog traffic google analyticsBlog traffic from organic searches is no doubt important. It keeps your old articles actively read, traffic levels high, and makes an excellent channel for new readers and subscribers. But how do you go abouts picking up this search engine traffic in such competitive SERPs?

Check your HTML
If you’re a WordPress user: excellent, you’re one step ahead of the game. WordPress was built with web semantics in mind, and it is very well optimized for search engines from the get-go. However, you will want to make sure you have the Optimal Title plugin installed and activated! This plugin will re-arrange the order in your <title> tags, putting the name of your post before the name of your blog. This is extremely important because search engines rank the first few words of your page title the most important. Also, make sure that your title tags are short and concise, especially on content pages.

If you’re not a WordPress user, read over your source code and make sure your code doesn’t contain too much crap. Whats really important is that you have title tags, and correctly used header (h1, h2) tags. The title of your article should also be in an h1 or h2 tag at least once within the body.

The Content
Keyword density refers to the amount of times a specific keyword is found within a block of content. Before publishing an article make sure you establish which search terms you want the content to be correlated with. Then, list a few common keywords or phrases related to that search term, and make sure you use them while you’re writing the article. To give them extra emphasis you can bold them, italicize them, or use them as headers.

Titling your content is the most important part of the process. Make sure your title contains your most important keywords, preferably near the beginning of the string. This is a little conflicting for blog writers who take pride in writing “hook” titles, because you often lose a lot of creativity and end up writing a spammy title that is clearly targeting the search engines. You will have to find a comfortable medium between the two to keep your readers, the search engines and yourself happy.

Images
If you took a gander at the pie chart above, you’ll notice that 11% of traffic came from google images. Naming images with keywords, and doing the same with the alt attribute will add an extra cherry to the cake of traffic you receive from the search engines.

Links and Trackbacks
The most important factor in getting that juicy search engine traffic is that you actually write content thats worth reading. If nobody is linking to you, odds are your content isn’t worth being read by thirsty searchers. The search engine algorithms rely heavily on links to establish a page’s importance. The most people who link to your content, the more the search engines will like it. However you want to achieve this is your decision, but writing a quality article would be the easiest.

Picking up extra traffic from search engines is not an overly difficult task. It just takes some thought and the continual production of new and interesting quality content that is tactfully published.

Zazz Post Ticker - WordPress Plugin

Current Build: 1.2 (Release: 02/28/07; Update: 02/12/08)

Overview

This plugin creates a zazzy post ticker which fades through your recent blog posts with a stylish JavaScript fading effect. To see an example of the plugin in action, it should be right above the title of this post.

Requirements

WordPress with MySQL. The newer the better (with both.)

Installation

  1. Download file zazz-post-ticker.zip
  2. Upload file zazz-post-ticker.php to your servers plugin folder (/wp-content/plugins/)
  3. Activate plugin in your WordPress admin, on the plugins page
  4. Paste the PHP code (below) in your layout wherever you want the ticker to appear

PHP Code

<?php if (function_exists('ticker_get_results')) ticker_get_results(); ?>

Customization

  • Style and Appearance - If you want to change the look of your slider, you can define the styles in your stylesheet with CSS. Example here
  • Ticker Functionality

CSS Example

div#the_post_ticker
{
	border-top: 2px dotted #CCC;
	border-bottom: 2px solid #CCC;
	padding: 4px;
	margin-bottom: 4px;
	font-size: 12px;
	font-family: Verdana;
	height: 40px;
	overflow: hidden;
}
div#the_post_ticker a
{
	font-weight: bold;
	text-decoration: none;
}
div#the_post_ticker a:hover
{
	text-decoration: underline;
}

This is my first plugin ever! Please leave feedback and comment if you are using it, or the reason why you aren’t using it. :)



Updates and Changes

  • 02/12/08 : 1.2 - Added $category_filters to allow users to set filter to show only specified category posts. Detailed post here.

My first WordPress Plugin

I just spent about 3 or 4 hours programming my first WordPerss plugin! I’m excited to release it to the world. The plugin is a nifty fading news ticker that scrolls through recent posts. It may have been done before (I haven’t checked) but I had the impulse to do some programming this afternoon and I’ve had this idea in my head for a while now. If you want to see it in action, just load up the homepage of this blog here and it should load up right above the most recent post. (Give it a moment, it switches stories every 5 seconds.)

If you’d be interested in using this plugin, please leave a comment and I’ll try to expedite an official release. I still need a name for it, at the moment its called “Post Ticker” which is outrageously generic. I’d love to come up with something zazzful (new word!)

PayPerPost handed me $100 free

I’m not sure where I originally read it originally, but a related blogger wrote that he opened an account with PayPerPost (advertising) and they deposited $100 free into his account to get him started. Being the envious bastard I am, I went and registered a PayPerPost account, popped in my CC info and then just left it idle. I left it idle for over a month, and today, pay day! I received an email from a PayPerPost staff member who has clearly stated in bold that “PayPerPost has deposited $100 in your advertiser account.” I’ll be using the money (and probably going in excess to the $100 so I don’t feel like a crook) to help increase the PageRank and Alexa rank for my local social networking website. If my experience goes well with PayPerPost, I may start using it to promote more of my web based endeavours.

If the blogger who posted about their free $100 initially reads this, please leave a comment so I can trackback the post!

*update* - Thanks to Carl from Zigire.net, who initially told me about the $100 giveaways :)

- Next »