G$earch

5 Websites to Watch The 2012 Olympic Games Online

Posted by Harshad

5 Websites to Watch The 2012 Olympic Games Online


5 Websites to Watch The 2012 Olympic Games Online

Posted: 03 Jul 2012 02:17 AM PDT

It’s the end of another four-year wait. After China’s spectacular opening ceremony back in 2008 (which raised so many bars in so many categories) we move to London for the 2012 Olympic Games. Once again, we get to watch the human spirit break barriers, renew records, inspire team work, and push us to go further than our bodies would possibly let us. And with the help of technology, we can actually catch all this and more from the comforts of our living room.

olympic games online 5 Websites to Watch The 2012 Olympic Games Online

Here we are featuring 5 channels to catch videos, photos, news and highlights of your favorite Olympic events. While some are region-restricted, you will probably find at least the one channel that works for your region. Also included in all of them are event schedules, recaps of what happened in past Olympics, news and updates that affect the biggest sports event in 2012 and how you, the viewers can benefit from staying on their channel. Without further ado, let’s start keeping tabs of our favorite teams and athletes!

1. Official Olympic Channel

Watch the Olympic games as well as highlight clips live, right on your browsers, YouTube-supported tablets or smartphones, and without having to pay a single penny. During the Olympics, 64 territories in Asia and Sub-Saharan Africa will enjoy live coverage of the Games on this official Olympics channel on YouTube, streamed by The International Olympic Committee (IOC). The channel will be providing more than 2,200 hours of the London 2012 Olympic Games live events, event highlights, news clips and medal finals – all with English commentary.

 

olympic youtube channel 5 Websites to Watch The 2012 Olympic Games Online

2. NBC Olympics

The NBC Olympics site offers live streaming coverage of the entire London 2012 Olympic Games online and on their mobile/tablet apps. All 32 sports and 302 events will be shown including live video feeds, highlights, event results, schedules, TV Listings, gold medal races and more. According to NBC, "Whatever is on schedule that day, if cameras are on it, we’ll stream it". That’s the good news.

The bad news is, NBC will only show the streamed videos on the Internet to users in the United States and U.S. Territories. Users outside of those covered locations will only have access to an extensive array of non-event videos.

nbc olympics 5 Websites to Watch The 2012 Olympic Games Online

3. Olympic.org

Olympic.org is the official source to what is happening at the Olympics. It’s the mother of all sites to view your favorite Olympic sports. Here, you can get the complete low-down of what goes on in the Games: live results, medal ceremonies, event schedules, athlete bios, team stats, news, photos and videos.

There are 10700 photos and 1600 videos to keep you busy for now. Stream the greatest Olympic moments, the hottest of rivalries, and watch the legends make history in HD from London 2012 Olympics.

olympic org 5 Websites to Watch The 2012 Olympic Games Online

4. CTVOlympics YouTube Channel

What better way to stream videos about the Olympics than from Youtube itself. Even better, there is a dedicated Youtube Channel called CTV Olympics that gives Canadians, an incredible means to view Olympics outside of London. CTVOlympics.ca is an exclusive source for videos and photos related to Olympic athletes, participating countries, the teams involved, event schedules and eventually game results. You can watch this massive event live online on its official YouTube channel as it provides in-depth coverage, sports analysis, athlete bios, and Olympic content right on your browser to viewers in Canada.

ctvolympics 5 Websites to Watch The 2012 Olympic Games Online

5. The Guardian

The Guardian is also providing awesome coverage of the Londons 2012 Olympic Games and if you check out their Olympics 2012 section, you’d be treated to a ton of freebies. They are featuring interactive guides in which you can observe the torch route, get a virtual tour of the Olympic Park (and the Velodrome) and a ranked list of 50 of the best medal hopes for Britain. Get a recap of stunning moments in the Olympics as well as sports-by-sports guide and video highlights of the Games. There is even a section called Olympic diaries where you read the personal thoughts of the sportsmen and women who are out there rooting for gold for the country.

the guardian 5 Websites to Watch The 2012 Olympic Games Online

Related posts:

  1. A Look Into: 6 Olympic Logo Designs
  2. 15 Web Design Trends to Watch Out For in 2012
  3. Happy New Year + 2012 Desktop Wallpaper
  4. State of the Internet 2012 [Infographic]

Rewriting URLs in WordPress: Tips and Plugins

Posted: 03 Jul 2012 02:25 AM PDT

The newest updates to WordPress have allowed for developers to customize their personal website very quickly. It’s simple to update areas of your theme, replace widgets in the sidebar, and even write your own custom PHP code functions. The expanse is huge – and one area of popularity is rewriting pretty URL permalinks.

wordpress Rewriting URLs in WordPress: Tips and Plugins

(Image Source)

There are a few methods you can use to go about updating the default WordPress rewrite system. In this tutorial I will share a few examples and demonstrate how simple the process can be. You will need some understanding of PHP to follow what’s going on in the code, but it’s so easy to copy and paste into your own template, there’s practically no work involved.

Understanding WP_Rewrite

If you are at all familiar with mod_rewrite on Apache servers then you’ll pick up on the WordPress rewrite syntax. Their system is still built on top of an .htaccess file, but all the rules are coded in PHP. This actually makes the process a bit easier since we have more control over writing our own URLs.

I recommend skimming the $wp_rewrite class page as it has tons of info on the subject. There are even small examples we can reference to make everything easier to understand. Most of the code can be written directly into your theme’s functions.php file. Let’s start by looking at the default rewrites already included with WordPress.

Content of $wp_rewrite->rules

By declaring the $wp_rewrite class as global we have access to all of the internal data. When you go to append your own rules these are added into an array with the name $wp_rewrite->rules. It’s important to remember this variable since you’ll likely need to reference the data many times during development.

<div><code>  <?php  global $wp_rewrite;  print_r($wp_rewrite->rules);  ?>  </code></div>  

I added this block of code into my theme’s page.php file. It will output a large array of data which looks like a big mess. But if you View Source on your page it’s actually easy to see which rewrite rules are matched to which filename. For example, let’s look at the rules for category rewrites:

[category/(.+?)/?$] => index.php?category_name=$matches[1]  

The bit on the left side in brackets is our Apache RewriteRule to look for. Starting with the section /category/ followed by any string of characters. If this is matched then the server knows to reference index.php?category_name= while replacing the variable on the end.

Setting Custom Permalinks

There is so much content to go over in the $wp_rewrite class alone. Many other properties can be referenced, such as $wp_rewrite->category_base or $wp_rewrite->author_base for pulling the default URL structures for these pages. But aside from pulling WP’s default settings we can also build our own rules.

Rebuilding the Author Base

When you enter the Permalinks settings page you have the option of resetting category and tags bases. However the option to reset your author base is strangely missing.

But we can use the add_rewrite_rule() from WordPress’ codex to integrate some new settings. In this case I’ve replaced /author/ with /writer/ but you could use whatever base you like. Additionally I’ve copied some of the other redirects for author pages and RSS feeds. You can add this block of code into your theme’s functions.php file.

add_action( 'init', 'add_author_rules' );  function add_author_rules() {      add_rewrite_rule(          "writer/([^/]+)/?",          "index.php?author_name=$matches[1]",          "top");        add_rewrite_rule(  	"writer/([^/]+)/page/?([0-9]{1,})/?",  	"index.php?author_name=$matches[1]&paged=$matches[2]",  	"top");        add_rewrite_rule(  	"writer/([^/]+)/(feed|rdf|rss|rss2|atom)/?",  	"index.php?author_name=$matches[1]&feed=$matches[2]",  	"top");        add_rewrite_rule(  	"writer/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?",  	"index.php?author_name=$matches[1]&feed=$matches[2]",  	"top");  }  

This function can be accessed even without using the $wp_rewrite variable. Some developers like this method because it’s simpler than hard-coding with class properties. However I’ve also noticed this method is not always reliable for some WordPress installations. There is actually a second option to add these rules on the hook after flushing your .htaccess (see below).

Author Base using generate_rewrite_rules

Writing for this method we will again need the global $wp_rewrite class. I’ve then setup a new variable named $new_rules which contains an associative array of data. My example code below just rewrites for the basic author page section.

function generate_author_rewrite_rules() {    global $wp_rewrite;    $new_rules = array(      "writer/([^/]+)/?" => "index.php?author_name=".$wp_rewrite->preg_index(1)    );    $wp_rewrite->rules = $new_rules + $wp_rewrite->rules;  }  

But if we want to include multiple pages and RSS feeds we can beef up the array. You have the option of creating a PHP function to push associative array data which may be a bit too complex. We could also split the data blocks via commas, behaving as separate entities in the array. Check out my updated code again written in functions.php theme file.

function generate_author_rewrite_rules() {    global $wp_rewrite;    $new_rules = array(      "writer/([^/]+)/?" => "index.php?author_name=".$wp_rewrite->preg_index(1),  	"writer/([^/]+)/page/?([0-9]{1,})/?" => "index.php?author_name=".$wp_rewrite->preg_index(1)."&paged=".$wp_rewrite->preg_index(2),  	"writer/([^/]+)/(feed|rdf|rss|rss2|atom)/?" => "index.php?author_name=".$wp_rewrite->preg_index(1)."&feed=".$wp_rewrite->preg_index(2),  	"writer/([^/]+)/feed/(feed|rdf|rss|rss2|atom)/?" => "index.php?author_name=".$wp_rewrite->preg_index(1)."&feed=".$wp_rewrite->preg_index(2)    );    $wp_rewrite->rules = $new_rules + $wp_rewrite->rules;  }  

Just remember that neither of these methods will work until after you’ve flushed the original rewrite rules. You will have to do this any time you make changes to these functions, but afterwards your new rules will stick indefinitely.

Flushing the Rewrite Rules

Whenever you make an update to the URL rewrite code, the changes are not applied immediately. You have to flush the .htaccess rewrite rules so your new code will be added. However performing this on every page init is extremely wasteful as it writes to the database and hard-refreshes the .htaccess file.

A better method is to access your permalinks page in the admin panel and re-save the changes. This always calls a flush_rewrite_rules so you never have to worry about users on the frontend experiencing loading troubles. And it only takes one time to re-save the page and update all the rules in your system. But if this doesn’t work you can try calling $wp_rewrite->flush_rules();

Using non-WP Rules

Inside the $wp_rewrite class we have access to dozens of properties. One of the more significant options is $wp_rewrite->non_wp_rules which collects an array of redirects which do not hit the index.php file.

This is actually used most often in WordPress plugin development. You can push a specific custom URL type (such as /calendar/june-2012/) into the backend of your website(/wp-content/plugins/calendarplug/myscript.php). But of course there are further uses for this associative array of custom rewrite rules other than plugins. I’ve provided an excellent example in the context below.

Masking your Theme Files

This is a common suggestion I see frequently on WordPress discussion boards. Ideally we’d like to reference some files inside the /wp-content/themes/mytheme/ folder with a more elegant URL. Notice that this will require a different set of WordPress rewrites to change the directory structure.

WordPress’ internal rewrite system always pushes content towards a single routing file. In the default case, we use index.php along with any extra query string data. But for hiding our standard template directory(/wp-content/themes/mytheme/*) we will need to display many different files.

add_action('generate_rewrite_rules', 'themes_dir_add_rewrites');    function themes_dir_add_rewrites() {    $theme_name = next(explode('/themes/', get_stylesheet_directory()));      global $wp_rewrite;    $new_non_wp_rules = array(      'css/(.*)'       => 'wp-content/themes/'. $theme_name . '/css/$1',      'js/(.*)'        => 'wp-content/themes/'. $theme_name . '/js/$1',      'http://media02.hongkiat.com/wordpress-urls-rewrite/(.*)'    => 'wp-content/themes/'. $theme_name . '/http://media02.hongkiat.com/wordpress-urls-rewrite/$1',    );    $wp_rewrite->non_wp_rules += $new_non_wp_rules;  }  

I’ve written a new function themes_dir_add_rewrites() to pull all the major content from these longer URLs and redirect them in the backend. Notice that we’re using this other mysterious property of the $wp_rewrite class named non_wp_rules. According to the docs, these are rules which do not direct to WP’s index.php file and will be handled on the server end.

What’s so great about these non-WP rules is that you can still manage the older URL method quite easily. There’s nothing stopping you from linking to /wp-content/themes/mytheme/http://media02.hongkiat.com/wordpress-urls-rewrite/logo.jpg. But it looks a whole lot nicer if you can reference /http://media02.hongkiat.com/wordpress-urls-rewrite/logo.jpg instead.

Helpful Tools & Plugins

There are just a few tools you can utilize if you are stuck with coding your own pretty URLs. The process is very difficult to grasp, so don’t get discouraged if you are struggling for a couple weeks. I feel the content will get easier as you spend more time practicing.

But to get started check out some of these handy rewrite tools & plugins. You probably won’t need all of them but it’s great to find such a large developer base working around WP rewrites.

Monkeyman Rewrite Analyzer

When first jumping into rewriting rules this plugin is a must-have. It does not actually change any of the rules for your website – it merely allows you to test out code and see which redirects go to which pages. It will even work for testing custom query variables for any custom post types.

rewrite analyzer screen2 Rewriting URLs in WordPress: Tips and Plugins

AskApache RewriteRules Viewer

This is similar to the plugin above except it doesn’t let you test your own rules. Instead this plugin will display all of your website’s default WP rules and where they redirect to. This will include all the major properties of $wp_rewrite such as your permalink settings and page/category/tags bases.

askapache rewrite plugins root Rewriting URLs in WordPress: Tips and Plugins

WP htaccess Control

Here you have a different set of rules for making new page redirects. The plugin has its own admin panel where you can edit variables such as your author base, page bases, and even append your own custom .htaccess rules.

This method is different compared to building your own using wp_rewrite. However it may be easier for techies who really know web servers and feel more comfortable writing directly into .htaccess.

wp htaccess control Rewriting URLs in WordPress: Tips and Plugins

Rewrite Rule Tester

This actually isn’t a WordPress plugin, but is definitely one handy tool to keep on file. You can copy over rewrite rules and test them for your website without ever editing your .htaccess file. This is the perfect method for removing bugs out of your syntax before launching live on the Web.

rewrite rules tester webapp Rewriting URLs in WordPress: Tips and Plugins

DW ReWrite

DW Rewrite is a very simple plugin which creates 3 unique pretty URLs immediately after installation. By default it will change admin, login, and registration links to /admin, /login, and /register respectively.

This can be great if you need a quick fix for a blog that features multiple authors. It will specifically hide the embarrassingly convoluted WordPress registration link(/wp-login.php?action=register).

Conclusion

I hope this tutorial can provide some examples to get you thinking about WordPress rewrites. The CMS is very popular and developers are still producing new features every day. Customizing your own URLs is such a huge piece of user-based functionality. It gives your website its own unique presence and branding compared to the default options.

If you are having trouble with rewrite rules it should never be difficult to undo the damage. By simply deleting the function code and flushing your .htaccess rules it would appear like nothing has changed. Be sure to check out some other similar articles you can find on the topic. And if you have any questions or comments you can share them with us in the post discussion area.

Related posts:

  1. Hardening WordPress Security: 25 Essential Plugins + Tips
  2. 7 Free E-Commerce WordPress Plugins
  3. How to add WordPress Related Posts Without Plugins
  4. 5 Essential WordPress Plugins For Comments

Blurry Text on MacBook Pro with Retina Display [QuickFix]

Posted: 05 Jul 2012 04:48 AM PDT

WIth more than 5 million pixels packed into a 15.4-inch display, Apple’s latest crowning achievement in its notebook line, the MacBook Pro with retina display has raised the bar for its competitors, making everything on the screen more vibrant and sharper than ever. Everything looks better on 2880 x 1800 pixels but here’s where we face a problem, third-party apps now look worse on the new MacBook Pro than they did when viewed on the previous Macbooks.

mbp retina Blurry Text on MacBook Pro with Retina Display [QuickFix]

That means that non-native apps that we use on a regular basis like Chrome, Firefox, Photoshop, MS Office etc that have yet to update their apps display now suffer from blurry text and low-quality graphics. Designers will see that images aren’t sharp at 100% and for web surfers using Chrome or Firefox, they’d see pixelated fonts and less-than optimum images.

The entire browsing experience is now a major turn-off.

Comparing browsers

To get an idea the extent of the change, check out the image shown below. Fonts are properly rendered and looking crisp-sharp as ever on Safari. Compare that to a view on Chrome or Firefox and you’ll have no such luck. Can you stand reading blurry text all day long?

chrome vs firefox vs safari Blurry Text on MacBook Pro with Retina Display [QuickFix]

Solutions

Is there a solution to this problem? Yes and No (or not yet). It’s now up to developers to update their apps to take advantage of the much-sharper retina display. In fact, we’ve stumbled upon some temporary fixes that can help improve your experience with the new MacBook Pro with retina display.

Firefox

Firefox is reported to be working on temporary fixes to cater to MacBook Pro users. You’d proably need to update to their latest browser for the changes to take effect. Hopefully the fixes won’t take too long.

Chrome

As for Google Chrome, development to make their browser ‘shine’ on retina display is already under way. Those who can’t wait will have to make do with Chrome Canary for the time being. Here’s a comparison of the display between the current version of Chrome and Chrome Canary.

chrome vs chrome canary Blurry Text on MacBook Pro with Retina Display [QuickFix]

However, if you choose to download Chrome Canary, bear in mind that it’s still in beta and complete breakdowns are to be expected, but trust in Google to make non-believers convert. One last bit about Chrome Canary is that it runs alongside stable Chrome.

Resolving resolutions for Native Apps

So far, native apps like iPhoto, Garageband, Final Cut Pro X are already updated for view on retina display but if you are seeing less-than satisfactory results in Keynote, Pages and Numbers, it’s probably still set in low resolution and it is solvable. Here’s what you need to do:

  • Go to Application folder
  • Look for Keynote, Pages, and/or Number
  • Right click > Get Info
  • Deselect "Open in low resolution"

open in low res Blurry Text on MacBook Pro with Retina Display [QuickFix]

Conclusion

It will take a while before all your favourite apps to get up to speed with retina-compliant enhancements. If this is an issue with your work or if you can’t function anywhere below optimum conditions, then you’d probably want to hang on to your old machine in the meantime.

Related posts:

  1. How to Display WordPress Sidebar on Other (Non WP) Sites
  2. How to Read .ePub Ebooks on Firefox and Chrome [Quicktip]
  3. 28 Fresh Photoshop Text Effect Tutorials
  4. How to Display/Update “Facebook Likes” Using Node.js

How To Schedule Facebook Birthday Greetings in Advance [Quicktip]

Posted: 02 Jul 2012 01:55 AM PDT

Often times, you forget to send your friends’ birthday wishes, be it on Facebook, via phone call or messages. Sure, it’s not a big deal to forget birthdays but it is nice to show your friends that you are always there for them in their lives, celebrating their great moments with them. Being too busy to remember is not a cool way to explain your absent-mindedness, when in the past you can easily find the time to prepare a birthday card for them.

birthdayfb How To Schedule Facebook Birthday Greetings in Advance [Quicktip]

So what can you do to keep up with birthday wishes, at least on Facebook? What could probably be the most efficient way is to schedule automated birthday wishes. Every time a birthday arrives, a birthday wish will be automatically posted on your friend’s Facebook Wall. Cool? Indeed, there is a way to get it done with BirthdayFB, a web application that will automatically do just that.

Connect Facebook with BirthdayFB

To get started, go to the official page of BirthdayFB and connect with your Facebook account.

birthdayfb connect How To Schedule Facebook Birthday Greetings in Advance [Quicktip]

Once connected, you will be redirected to the main page, where you will see a list of upcoming birthdays of your friends on Facebook.

birthdayfb upcoming How To Schedule Facebook Birthday Greetings in Advance [Quicktip]

Scheduling birthday wishes with BirthdayFB

Scheduling birthday message is easy: click on the ‘Write Messages’ tab and you will be redirected to a page where you can write your birthday messages.

birthdayfb write How To Schedule Facebook Birthday Greetings in Advance [Quicktip]

As you can see on the above screenshot, there are 4 sections to fill up and the steps are as follow;

  1. Firstly, select the wish you want to post on your friend’s wall. You can use the dropdown menu to select ‘canned’ messages. Canned messages are pre-set messages you have saved earlier, or that are prepared by BirthdayFB.

  2. Use the text box to write your own messages, if you prefer to not use the ‘canned’ messages from the dropdown menu.

  3. If you write your own message and you want to save it as a canned message, check the ‘Save as a canned message’ option so you can use it again.

  4. Click ‘Save’ when you are ready to schedule the message.

Canned messages

Canned messages are saved and re-usable messages. Every time when you save a new message, it will appear in your collection.

To manage your canned messages, click on the ‘Canned Messages’ tab. To create a new pre-set or canned message, click on ‘+New Canned Messages’. You can also edit or remove the existing messages by clicking on ‘Edit’ or ‘Remove’ buttons on the right side of every message.

birthdayfb canned How To Schedule Facebook Birthday Greetings in Advance [Quicktip]

The canned messages that you can edit are those that you saved, but the ones prepared by BirthdayFB will remain as such.

Scheduled Messages

The messages once scheduled, will be posted on your friend’s wall during the wee hours of their birthdays; that said, you will only be able to edit those messages before it gets posted.

To edit, click on ‘Scheduled Messages’ tab and click on the ‘Edit’ button to customize your messages.

birthdayfb scheduled How To Schedule Facebook Birthday Greetings in Advance [Quicktip]

Conclusion

With this Facebook ‘helper’, you don’t have to worry about forgetting or having to rush to post birthday wishes on your friends’ Facebook Wall on their birthdays.

Related posts:

  1. How to Setup Messages + Facebook Chat in OS X Lion [Quicktip]
  2. How to View Facebook Photos, Pinterest Style [Quicktip]
  3. How to Listen to Music with Friends on Facebook [Quicktip]
  4. Disabling Activity Posts from Facebook Apps [Quicktip]

0 comments:

Post a Comment