Save $45 on Roku + 6 Months of Hulu Plus

Celebrate the dads and grads in your life with this special offer. The Roku HD streaming player connects easily to TVs with the included HDMI cable. Simply connect the Roku HD to a wireless network to start streaming current hit TV shows, classic series, and acclaimed movies in high-def — it only takes minutes to set up!

Hurry, this limited-time offer is only available until Father’s Day, June 17, 2012.

6 Months Of Hulu Plus and Save 45 On Roku

Posted in Marketing, Tech Tips | Tagged , , , | Leave a comment

Why not to use 1and1 for hosting

And this is why I don’t think of 1and1 as a serious company for web hosting:

Why Not To Use 1and1 For Hosting

Posted in Server Admin, Server Administration | Tagged , | Leave a comment

Strong, Anti-Break RJ45 Connectors

I hate it when the tab on my RJ45 connectors ends up breaking off and then the connector comes unplugged from my computer and I lose internet. I heard this happens a lot to people playing XBOX as well. I searched the internet for strong and anti-breaking RJ45 connectors, ones that would be durable and resilient but the only thing I could find was the ones with little boots that protect them, I believe they are called anti-snag boots. Well, instructables.com has a nice tutorial for how to fix your own RJ45 connectors using two zip ties:

Strong  Anti Break Rj45 Connectors

You don’t need many tools to be able to fix your RJ45 connectors:

Repair Rj45 Connectors

You can find the tutorial here.

Please let me know if you find another solution to the common RJ 45 problem, possibly some real Strong, Anti-Break RJ45 Connectors.

There is also another thing they have posted about protecting the plug with Sugru Ethernet RJ45 Plug Protector:

Sugru Ethernet Rj45 Plug Protector

That tutorial can be found here.

Posted in Design, Tech Tips | Tagged , , , , , | Leave a comment

array_search case insensitive

Case Insensitive Array Search PHPPHP’s array_search claims that it suppors a case insensitive search, well, sort of, with this message:

> If needle is a string, the comparison is done in a case-sensitive manner.

user says:
> for case insensitive array_search you could use:

function array_search_i($str,$array){
foreach($array as $key => $value) {
if(stristr($str,$value)) return $key;
}
return false;
}

stefano says:
> for searching case insensitive better this:

array_search(strtolower($element),array_map(‘strtolower’,$array));

Posted in Tech Tips, Web Development | Tagged , , | Leave a comment

strtotime examples

Examples for strtotimeHere are some example strtotime syntaxes for PHP. Leave a comment with an example if you like.

strtotime(‘today 14:00’);
strtotime(‘tomorrow 14:00’);
strtotime(‘tomorrow 2:00pm’);
strtotime(‘now +2 hours’);
strtotime(‘now +2 minutes’);
strtotime(‘now +24 hours’);
strtotime(‘now +12 hours’);
strtotime(‘today +3 days’);
strtotime(‘now +5 days’);

A Quick reference of accepted input:

Numeric steps (+1, -1 …)
Numeric date/time (Y-m-d, H:i:s)
Ordinal names / numbers [first – twelfth = 1 – 12] *
Special ordinal name / numbers (last = -1, this = 0, next = 1)
Special words (tomorrow, yesterday, ago, fortnight, now, today,
day, week, month, year, hour, minute, min, second, sec) **
Days / months [sunday – saterday, sun – sat, January – December, Jan – Dec]
Timezones (TZ=”…”)

\* second is reserved for seconds in time notation, therefore is not allowed here

\*\* plurals are also allowed by adding an ‘s’

via php manual

Posted in Tech Tips, Web Development | Tagged , | Leave a comment

Do Not Reply E-mail Addresses

When creating a do-not reply automated e-mail account I thought it would be nice to see if there was an industry standard or a convention for these addressed. There are the ones I could find and wanted to share. If you have thoughts on setting up a do-not-reply address or more examples please post them in the comments below.

Do Not Reply E Mail Addresses

Posted in Marketing, Tech Tips | Tagged , , , , | Leave a comment

phpmyadmin: Drag And Drop File Upload

I use phpMyAdmin to manage mySql databases quite often and I find myself uploading / importing SQL files. I’ve gotten a little spoiled with WordPress’ HTML5 drag and drop ajax style uploader. Every time I go to use phpMyAdmin I start wishing that it had a HTML5 style drag-and-drop file uploader, something like this:

Phpmyadmin Drag And Drop File Upload

I think it would be fairly easy to write a plugin and implement this idea but I have not done it yet. Leave a comment if the lack of a drag and drop HTML5 file uploader for phpMyadmin bugs you too.

Posted in Server Administration, Tech Opinion, Web Development | Tagged , , , , , | Leave a comment

Bitly: Verify a Tracking Domain

Bitly offers the ability to set up a “Tracking Domain” which, according to bit.ly:

> If you have a website, you can gather metrics on all bitmarks that point to your site.

Bitly Verify A Tracking Domain

There is a problem with verifying the domain using an HTML file (read on, see below).

Doing this also lets you set up bit.ly so that if someone shortens a URL to your domain it will use your custom shortener instead of the default bit.ly shortener.

You can change these settings at https://bitly.com/a/settings/advanced

###Step 1

Enter the root domain of your main site, to be used for tracking when end users are shortening links for your site.

> willshouse.com

The tracking domain is different than the custom short domain.
Example: The New York Times tracking domain is nytimes.com, Their short domain is nyti.ms.

###Step 2

You have set your tracking domain as: willshouse.com.

To enable tracking for this domain, we need to verify that you own the domain. You can demonstrate ownership of your domain by choosing any one of the following (whichever is easiest for you):

Add an HTML tag to your web site’s home page:

add the following tag to https://techblog.willshouse.com/

Upload an HTML file to your web site:

download a zip file containing an HTML page here. Upload this HTML page so that it is available at:

https://techblog.willshouse.com/01234567890.html

Make a DNS change:

create a CNAME record for `01234567890.willshouse.com` pointing to `cname.bitly.com`

###Problem Verifying Domain using HTML file

I ran into a problem of verifying the domain name using the HTML zip file. I downloaded the zip file and extracted it, and got something like `01234567890.html` but it was blank / empty inside. So I was trying to verify and bit.ly was telling me:

> Verification started. Check back in a few minutes. It’s now 49 minute(s) past the hour.
> You have set your tracking domain as: willshouse.com.

This would never complete though, and the tracking domain would never be verified. The problem is that you need content inside of the HTML file that you put on your server. The content you need to add is in this format:

bitly-verification: 01234567890.html

That is `bitly-verification` followed by the file name that it wants you to use.

Posted in Marketing, Tech Tips, Web Development | Tagged , , | Leave a comment

Instabir: Unexpected token (

Are you using Instabir’s a/b testing and getting the javascript error:

Unexpected token (

when your page loads? This is most likely because you are using either of these files:

jquery.ab.js
jquery-ab-hosted.js

Instabir Unexpected Token

Unfortunately the un-minimized versions of Instabir’s a/b testing files will yield an `Unexpected token` error. You can either switch to using the minimized versions of the jQuery a/b testing plugin or you can fix the start and end of the file:

The start of the file needs to be changed from this:

// jQuery AB Testing
// Website: www.instabir.com

function($){

To this:

// jQuery AB Testing
// Website: www.instabir.com

(function($){

Notice the `(` before the `function` keyword.

Other (paid) A/B testing tools include GWO, Omniture, Sitespect, and Visual Website Optimizer.

Posted in Marketing, Web Development | Tagged , , | Leave a comment

Welcome to Events 2.0! This is a HUGE upgrade from 1.6.5. Please make sure you have backed up before proceeding any further.

Welcome To Events 2 0 This Is A Huge Upgrade From 1 6 5 Please Make Sure You Have Backed Up Before Proceeding Any Further 1
If you are getting this error when using “The Events Calendar” it’s because on some servers Tribe’s query for checking legacy events has a flaw. This is the message:

> Welcome to Events 2.0! This is a HUGE upgrade from 1.6.5. Please make sure you have backed up before proceeding any further. You can easily revert to an old version if you want to backup first. This upgrade includes two major steps, migrating data & updating your templates as necessary. There have been significant changes to the template tags and functions. Check out our walkthrough on the upgrade before proceeding and check out the FAQ & Knowledge base from the support page. If you’re new to The Events Calendar, you may want to review our new user primer.

> You have events that need to be migrated. Please visit the bottom of the settings page to perform the migration.

(I’d also like to point out that the link to the settings page needs to be updated because it is broken, but you can access the settings page via `Settings->The Events Calendar` in the admin menu.

Anyhow, this is the code that the plugin uses to check for legacy events, it includes two functions:

private static function getLegacyEvents( $number = -1 ) {
// TODO: needs to account for either v1 posts or v2 ‘sp_events’
$query = new WP_Query( array(
‘post_status’ => ‘published’,
‘posts_per_page’ => $number,
‘meta_key’ => ‘_EventStartDate’,
‘category_name’ => ‘xEvents’
));

if (count($query->posts)) {
TribeEvents::debug( __( ‘Install has 1 or more legacy event!’, ‘tribe-events-calendar’ ), false, ‘warning’ );
}
return $query->posts;
}

And the second function:

public static function hasLegacyEvents() {
return count( self::getLegacyEvents( 1 ) );
}

The problem is that on some machines the query object that is returned looks like this:

[posts] => Array
(
[0] => Array
(
[ID] => 0
[filter] => raw
)

You can fix this by editing this file:

/wp-content/plugins/the-events-calendar/lib/tribe-the-events-calendar-import.class.php

And changing the second function to check for the empty post (around line 144):

/**
* Test for legacy events
*
* @return boolean for legacy events
*/
public static function hasLegacyEvents() {
$test = self::getLegacyEvents( 1 );
if(count($test) < 1 || empty($test[0]['ID'])) { return false; } return count($test); } I've contacted Tribe, but please let them know they need to update their plugin - it's a lot of trouble to maintain plugin fixes if they aren't incorporated in upgrades.

Posted in Web Development | Tagged , , , | Leave a comment