<?xml version="1.0" encoding="UTF-8"?>
<feed xml:lang="en-US" xmlns="http://www.w3.org/2005/Atom">
  <title>USINGMAC.com - Home</title>
  <id>tag:www.usingmac.com,2008:mephisto/</id>
  <generator uri="http://mephistoblog.com" version="0.7.3">Mephisto Noh-Varr</generator>
  <link href="http://www.usingmac.com/feed/atom.xml" rel="self" type="application/atom+xml"/>
  <link href="http://www.usingmac.com/" rel="alternate" type="text/html"/>
  <updated>2008-05-12T14:26:34Z</updated>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-05-12:5862</id>
    <published>2008-05-12T14:25:00Z</published>
    <updated>2008-05-12T14:26:34Z</updated>
    <category term="Internet"/>
    <link href="http://www.usingmac.com/2008/5/12/safari-exporting-bookmarks-into-html-file" rel="alternate" type="text/html"/>
    <title>Safari - Exporting Bookmarks into HTML File</title>
<summary type="html">&lt;p&gt;
There are 2 ways to export Safari Bookmarks plist file into HTML file, the first one is the geeky way and the other is using third party application. Let's see how it can be done.
&lt;/p&gt;

&lt;h4&gt;The Geeky Way&lt;/h4&gt;
&lt;p&gt;
Open your Terminal and execute this command line, which will add Debug menu to Safari :
&lt;/p&gt;</summary><content type="html">
            &lt;p&gt;
There are 2 ways to export Safari Bookmarks plist file into HTML file, the first one is the geeky way and the other is using third party application. Let's see how it can be done.
&lt;/p&gt;

&lt;h4&gt;The Geeky Way&lt;/h4&gt;
&lt;p&gt;
Open your Terminal and execute this command line, which will add Debug menu to Safari :
&lt;/p&gt;

&lt;pre&gt;
defaults write com.apple.Safari IncludeDebugMenu 1
&lt;/pre&gt;

&lt;p&gt;
After relaunching Safari, you now can choose File ▸ Export Bookmarks... And the rest of the steps should be obvious.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3165/2485906917_67f9079d04_o.png&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;Safari Bookmarks Extractor&lt;/h4&gt;
&lt;p&gt;
Go to &lt;a href=&quot;http://www.arcadiadesign.it/deerdesign/sbe/english/english.html&quot;&gt;Arcadia Design&lt;/a&gt; homepage and download Safari Bookmarks Extractor (144KB). After that, the application clearly explains how to export Safari bookmarks.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3022/2485906843_55b07ed5a6_o.png&quot; /&gt;
&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-05-11:5802</id>
    <published>2008-05-11T14:38:00Z</published>
    <updated>2008-05-11T18:39:24Z</updated>
    <category term="Screen Savers"/>
    <link href="http://www.usingmac.com/2008/5/11/top-8-mac-screensavers" rel="alternate" type="text/html"/>
    <title>Top 8 Mac Screensavers</title>
<summary type="html">&lt;h4&gt;&lt;a href=&quot;http://www.reallyslick.com/&quot;&gt;Hyperspace and Helios&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;
The screensaver is nice, giving you the image of ultra high speed. However, They are quite heavy to be processed. They can be downloaded &lt;a href=&quot;http://seiryu.home.comcast.net/software/Hyperspace1.1.2.dmg.gz&quot; title=&quot;Hyperspace Screensaver&quot;&gt;here&lt;/a&gt; for Hyperspace and &lt;a href=&quot;http://seiryu.home.comcast.net/~seiryu/software/Helios1.4.2.dmg.gz&quot; title=&quot;Helios Screensaver&quot;&gt;here&lt;/a&gt; for Helios.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2304/2483186313_24be6fba8e_o.jpg&quot; width=&quot;300&quot; /&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3149/2483185505_224b29a542_o.jpg&quot; width=&quot;300&quot; /&gt;
&lt;/p&gt;</summary><content type="html">
            &lt;h4&gt;&lt;a href=&quot;http://www.reallyslick.com/&quot;&gt;Hyperspace and Helios&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;
The screensaver is nice, giving you the image of ultra high speed. However, They are quite heavy to be processed. They can be downloaded &lt;a href=&quot;http://seiryu.home.comcast.net/software/Hyperspace1.1.2.dmg.gz&quot; title=&quot;Hyperspace Screensaver&quot;&gt;here&lt;/a&gt; for Hyperspace and &lt;a href=&quot;http://seiryu.home.comcast.net/~seiryu/software/Helios1.4.2.dmg.gz&quot; title=&quot;Helios Screensaver&quot;&gt;here&lt;/a&gt; for Helios.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2304/2483186313_24be6fba8e_o.jpg&quot; width=&quot;300&quot; /&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3149/2483185505_224b29a542_o.jpg&quot; width=&quot;300&quot; /&gt;
&lt;/p&gt;


&lt;h4&gt;&lt;a href=&quot;http://wakaba.c3.cx/s/lotsablankers/lotsaglass.html&quot;&gt;LotsaGlass&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;
It can transform itself and it has many unique shapes. I really hope I can have a glass like this for real. You can get the screensaver &lt;a href=&quot;http://wakaba.c3.cx/releases/mac/LotsaGlass1.2.zip&quot; title=&quot;LotsaGlass Screensaver&quot;&gt;here&lt;/a&gt;.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2182/2483183495_28005c48ee_o.png&quot; width=&quot;300&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;&lt;a href=&quot;http://www.electricsheep.org/&quot;&gt;Electric Sheep&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;
Download &lt;a href=&quot;http://electricsheep.org/electricsheep-2.6.9-universal.dmg&quot; title=&quot;ElectricSheep Screensaver&quot;&gt;here&lt;/a&gt;.
&lt;/p&gt;
&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3218/2484000292_3d3fc6b5b5_o.jpg&quot; width=&quot;300&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;&lt;a href=&quot;http://bodysoulspirit.deviantart.com/art/Time-Machine-Saver-Update-80034933&quot;&gt;Time Machine&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;
As a clone of Time Machine animation, this screensaver gets many attention also. Download it &lt;a href=&quot;http://www.deviantart.com/download/80034933/Time_Machine_Saver_Update_by_bodysoulspirit.zip&quot; title=&quot;Time Machine Screensaver&quot;&gt;here&lt;/a&gt; and drop it to your screensaver pane.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2207/2483184007_22b0130da8_o.jpg&quot; width=&quot;300&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;&lt;a href=&quot;http://www.objective-cocoa.org/fenetresvolantes/en/index_en.html&quot;&gt;Fenetres Volantes&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;
Let's fly! The screensaver can be downloaded &lt;a href=&quot;http://www.objective-cocoa.org/fenetresvolantes/en/download_assets/fenetresvolantes_v1_1_ub.zip&quot; title=&quot;Fenetres Volantes Screensaver&quot;&gt;here&lt;/a&gt;.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3053/2483183401_5a71ed8709_b.jpg&quot; width=&quot;300&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;&lt;a href=&quot;http://wakaba.c3.cx/s/lotsablankers/lotsawater.html&quot;&gt;LotsaWater&lt;/a&gt;&lt;/h4&gt;
&lt;p&gt;
If you haven't ever seen your Mac drowned in water, you can try this screensaver out. It gives the effect of your whole display being drowned! You can download it &lt;a href=&quot;http://wakaba.c3.cx/releases/mac/LotsaWater1.4j.zip&quot; title=&quot;LotsaWater screensaver&quot;&gt;here&lt;/a&gt;.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2255/2483185897_644a8188b3_o.jpg&quot; width=&quot;300&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;Flurry&lt;/h4&gt;
&lt;p&gt;
And still, Flurry is the best screensaver for Mac OS X.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2034/2483183613_0c396ec4b7_o.png&quot; width=&quot;300&quot; /&gt;
&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-05-10:5707</id>
    <published>2008-05-10T12:32:00Z</published>
    <updated>2008-05-10T12:33:16Z</updated>
    <category term="Tip and Tricks"/>
    <link href="http://www.usingmac.com/2008/5/10/finder-plain-list-view" rel="alternate" type="text/html"/>
    <title>Finder - Plain List View</title>
<summary type="html">&lt;h4&gt;Activate Plain Finder&lt;/h4&gt;
&lt;p&gt;
If you dislike the blue and white stripes on your Finder list view, you can use following line of Terminal command to make the background display plain white.
&lt;/p&gt;

&lt;pre&gt;
defaults write com.apple.finder FXListViewStripes -bool FALSE
killall Finder
&lt;/pre&gt;</summary><content type="html">
            &lt;h4&gt;Activate Plain Finder&lt;/h4&gt;
&lt;p&gt;
If you dislike the blue and white stripes on your Finder list view, you can use following line of Terminal command to make the background display plain white.
&lt;/p&gt;

&lt;pre&gt;
defaults write com.apple.finder FXListViewStripes -bool FALSE
killall Finder
&lt;/pre&gt;
&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2144/2480519736_2b37418854_o.png&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;Revert Back&lt;/h4&gt;
&lt;p&gt;
Maybe you want to revert back to original display of your Finder list, you can use following Terminal command :
&lt;/p&gt;

&lt;pre&gt;
defaults write com.apple.finder FXListViewStripes -bool TRUE
killall Finder
&lt;/pre&gt;

&lt;p&gt;
And you will get the previous blue and white stripes Finder list.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2145/2480519656_15e8ca92f3_o.png&quot; /&gt;
&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-05-09:5620</id>
    <published>2008-05-09T07:45:00Z</published>
    <updated>2008-05-09T13:58:33Z</updated>
    <category term="Spotlight"/>
    <link href="http://www.usingmac.com/2008/5/9/spotlight-indexing" rel="alternate" type="text/html"/>
    <title>Spotlight - Indexing</title>
<summary type="html">&lt;h4&gt;Prevent Spotlight Indexing&lt;/h4&gt;
&lt;p&gt;
Sometimes you don't want your Spotlight to index some parts of your Mac, e.g. your backup drive. If that's the case, you can set up your Spotlight to prevent searching in several locations. This setting can be performed under &lt;code class=&quot;special-term&quot;&gt;System Preferences ▸ Spotlight ▸ Privacy&lt;/code&gt;. Adding that particular folder into the pane provided will result in Spotlight stop indexing that folder.&lt;/code&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2167/2478028942_3c1f98dda3_o.png&quot; /&gt;
&lt;/p&gt;</summary><content type="html">
            &lt;h4&gt;Prevent Spotlight Indexing&lt;/h4&gt;
&lt;p&gt;
Sometimes you don't want your Spotlight to index some parts of your Mac, e.g. your backup drive. If that's the case, you can set up your Spotlight to prevent searching in several locations. This setting can be performed under &lt;code class=&quot;special-term&quot;&gt;System Preferences ▸ Spotlight ▸ Privacy&lt;/code&gt;. Adding that particular folder into the pane provided will result in Spotlight stop indexing that folder.&lt;/code&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2167/2478028942_3c1f98dda3_o.png&quot; /&gt;
&lt;/p&gt;



&lt;h4&gt;ReIndex Spotlight&lt;/h4&gt;
&lt;p&gt;
If you want Spotlight to reindex a certain volume, you can use following terminal line :
&lt;/p&gt;
&lt;pre&gt;
sudo mdutil -E -p &quot;/Volumes/Mac HD&quot;
&lt;/pre&gt;
&lt;p&gt;
Note : The volume name &lt;code class=&quot;special-term&quot;&gt;Mac HD&lt;/code&gt; is just for example, you should change it accordingly to the drive you want Spotlight to reindex.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2072/2477217513_2b1bbf8221_o.jpg&quot; /&gt;
&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-05-04:5275</id>
    <published>2008-05-04T14:43:00Z</published>
    <updated>2008-05-04T14:44:29Z</updated>
    <category term="Tip and Tricks"/>
    <link href="http://www.usingmac.com/2008/5/4/finder-checking-total-size-of-files" rel="alternate" type="text/html"/>
    <title>Finder: Checking Total Size of Files</title>
<summary type="html">&lt;p&gt;
When you want to check the size of a single file, highlighting the file followed by pressing &lt;img src=&quot;/images/Command.jpg&quot; /&gt;I (Get Info) is enough to extract out the file size.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2061/2464419482_dbe0df1aae_o.png&quot; /&gt;
&lt;/p&gt;</summary><content type="html">
            &lt;p&gt;
When you want to check the size of a single file, highlighting the file followed by pressing &lt;img src=&quot;/images/Command.jpg&quot; /&gt;I (Get Info) is enough to extract out the file size.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2061/2464419482_dbe0df1aae_o.png&quot; /&gt;
&lt;/p&gt;
&lt;p&gt;
However, if you do the same when you highlight multiple files, a lot of File Info Pane will appear. In order to pretend this to happen and you only get a single pane that display the total size of selected files, you can use &lt;img src=&quot;/images/Option.jpg&quot; /&gt;&lt;img src=&quot;/images/Command.jpg&quot; /&gt;I (Show Inspector).
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2380/2463614739_5fa1084b0e_o.png&quot; /&gt;
&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-05-02:5193</id>
    <published>2008-05-02T15:48:00Z</published>
    <updated>2008-05-02T15:50:39Z</updated>
    <category term="Application"/>
    <category term="Tip and Tricks"/>
    <link href="http://www.usingmac.com/2008/5/2/finder-icons-on-toolbar" rel="alternate" type="text/html"/>
    <title>Finder - Icons on Toolbar</title>
<summary type="html">&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3024/2458874501_89b95a9048_o.jpg&quot; /&gt;
&lt;/p&gt;

&lt;p&gt;
Do you want to use your Finder's toolbar as your additional Dock?
&lt;/p&gt;</summary><content type="html">
            &lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3024/2458874501_89b95a9048_o.jpg&quot; /&gt;
&lt;/p&gt;

&lt;p&gt;
Do you want to use your Finder's toolbar as your additional Dock?
&lt;/p&gt;


&lt;h4&gt;Putting Icons on Finder's Toolbar&lt;/h4&gt;
&lt;p&gt;
It's really easy to put those applications' icon onto your Finder's toolbar, you only need to &lt;code class=&quot;special-term&quot;&gt;Drag&lt;/code&gt; icons one by one to your Finder's toolbar, &lt;code class=&quot;special-term&quot;&gt;Hold&lt;/code&gt; on for a second or two until the square brackets appear and &lt;code class=&quot;special-term&quot;&gt;Release&lt;/code&gt; it.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2046/2459708796_798f2745f7_o.jpg&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;Taking Off from Toolbar&lt;/h4&gt;
&lt;p&gt;
When you're getting bored with those icons on your Finder's toolbar, you can easily take them off by &lt;code class=&quot;special-term&quot;&gt;Pressing &lt;img src=&quot;/images/Command.jpg&quot; /&gt;&lt;/code&gt; followed by &lt;code class=&quot;special-term&quot;&gt;Dragging&lt;/code&gt; the icon off the toolbar. It's that easy.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3279/2459709002_3751ddfb1d_o.jpg&quot; /&gt;
&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-04-30:5115</id>
    <published>2008-04-30T15:51:00Z</published>
    <updated>2008-04-30T17:56:32Z</updated>
    <category term="Email and Chat"/>
    <link href="http://www.usingmac.com/2008/4/30/apple-mail-setting-gmail-account" rel="alternate" type="text/html"/>
    <title>Apple Mail - Setting Gmail Account</title>
<summary type="html">&lt;p&gt;
I found this tutorial from Google really useful when you want to create new Gmail account for your Apple Mail application.
&lt;/p&gt;

&lt;h4&gt;Step 1. Mail ▸ Preferences...&lt;/h4&gt;
&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3069/2454232313_8830d3f2e6_o.jpg&quot; width=&quot;400&quot; /&gt;
&lt;/p&gt;</summary><content type="html">
            &lt;p&gt;
I found this tutorial from Google really useful when you want to create new Gmail account for your Apple Mail application.
&lt;/p&gt;

&lt;h4&gt;Step 1. Mail ▸ Preferences...&lt;/h4&gt;
&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3069/2454232313_8830d3f2e6_o.jpg&quot; width=&quot;400&quot; /&gt;
&lt;/p&gt;


&lt;h4&gt;Step 2. Accounts ▸ Add New Account&lt;/h4&gt;
&lt;p&gt;
Fill in your name, full Gmail address and your Gmail password. It will look like image below.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2241/2455059282_a3191ed678_o.jpg&quot; width=&quot;400&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;Step 3. Incoming Mail Server&lt;/h4&gt;
&lt;p&gt;
Select IMAP as your account type and use &lt;code class=&quot;special-term&quot;&gt;imap.gmail.com&lt;/code&gt; as your incoming mail server.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3102/2454232657_3a4b9fd88a_o.jpg&quot; width=&quot;400&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;Step 4. Outgoing Mail Server&lt;/h4&gt;
&lt;p&gt;
Use &lt;code class=&quot;special-term&quot;&gt;smtp.gmail.com&lt;/code&gt; as your outgoing mail server and use your correct Gmail address and password for authentication.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2093/2455059650_ca0abc52d1_o.jpg&quot; width=&quot;400&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;Step 5. Summary&lt;/h4&gt;
&lt;p&gt;
Read the summary and click on create to confirm your creating new account.
&lt;/p&gt;

&lt;h4&gt;Result&lt;/h4&gt;
&lt;p&gt;
Now you can see your new Gmail account has been added to your Apple Mail Accounts.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3138/2454233069_cd12a8aa99_o.jpg&quot; width=&quot;400&quot; /&gt;
&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-04-29:5065</id>
    <published>2008-04-29T13:42:00Z</published>
    <updated>2008-04-29T14:41:41Z</updated>
    <category term="Internet"/>
    <category term="Tip and Tricks"/>
    <link href="http://www.usingmac.com/2008/4/29/safari-and-firefox-quick-google-search" rel="alternate" type="text/html"/>
    <title>Safari and Firefox - Quick Google Search</title>
<summary type="html">&lt;p&gt;
Usually, what will you do when you want to start new search with Google search bar on the top-right corner of your web browser? There are three ways to do that.
&lt;/p&gt;

&lt;h4&gt;Type 1. Google Homepage&lt;/h4&gt;
&lt;p&gt;
This is the least advanced way. However, most of my friends still use this way. First, you open new tab &lt;code&gt;(shortcut : &lt;img src=&quot;/images/Command.jpg&quot; /&gt;T)&lt;/code&gt;, followed by typing in the url address &quot;&lt;a href=&quot;http://www.google.com&quot;&gt;www.google.com&lt;/a&gt;&quot;, filling in the search term and Google will return you the result.
&lt;/p&gt;

&lt;p&gt;
The advantage of using this way is that you can see Google homepage which in special occasion, the logo is changed.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2408/2134069920_f8ed26cd6d.jpg?v=0&quot; /&gt;
&lt;/p&gt;</summary><content type="html">
            &lt;p&gt;
Usually, what will you do when you want to start new search with Google search bar on the top-right corner of your web browser? There are three ways to do that.
&lt;/p&gt;

&lt;h4&gt;Type 1. Google Homepage&lt;/h4&gt;
&lt;p&gt;
This is the least advanced way. However, most of my friends still use this way. First, you open new tab &lt;code&gt;(shortcut : &lt;img src=&quot;/images/Command.jpg&quot; /&gt;T)&lt;/code&gt;, followed by typing in the url address &quot;&lt;a href=&quot;http://www.google.com&quot;&gt;www.google.com&lt;/a&gt;&quot;, filling in the search term and Google will return you the result.
&lt;/p&gt;

&lt;p&gt;
The advantage of using this way is that you can see Google homepage which in special occasion, the logo is changed.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2408/2134069920_f8ed26cd6d.jpg?v=0&quot; /&gt;
&lt;/p&gt;


&lt;h4&gt;Type 2. New Tab and Search Bar&lt;/h4&gt;
&lt;p&gt;
In this way, you will open a new tab &lt;code&gt;(shortcut : &lt;img src=&quot;/images/Command.jpg&quot; /&gt;T)&lt;/code&gt;, move cursor to search box &lt;code&gt;(shortcut : &lt;img src=&quot;/images/Command.jpg&quot; /&gt;L&lt;img src=&quot;/images/Tab.jpg&quot; /&gt; or &lt;img src=&quot;/images/Option.jpg&quot; /&gt;&lt;img src=&quot;/images/Command.jpg&quot; /&gt;F for Safari and &lt;img src=&quot;/images/Command.jpg&quot; /&gt;K for Firefox)&lt;/code&gt;, type the search term and Google will bring you to the result page for your search.
&lt;/p&gt;

&lt;p /&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2150/2452098390_3ba75a8465_o.png&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;Type 3. Search Bar and Open Search in New Tab&lt;/h4&gt;
&lt;p&gt;
Fortunately, you don't really need to open new tab before you want to perform new search with Google. You can jump quickly to the search bar with the shortcut provided (as exposed before), type in your search term and then open url in new tab &lt;code&gt;(shortcut : &lt;img src=&quot;/images/Command.jpg&quot; /&gt;&lt;img src=&quot;/images/Return.jpg&quot; /&gt; for Safari and &lt;img src=&quot;/images/Option.jpg&quot; /&gt;&lt;img src=&quot;/images/Return.jpg&quot; /&gt; for Firefox)&lt;/code&gt;. In return, you will have new tab opened with the search result from Google.
&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-04-28:5011</id>
    <published>2008-04-28T10:23:00Z</published>
    <updated>2008-04-28T10:24:57Z</updated>
    <category term="Internet"/>
    <category term="Tip and Tricks"/>
    <link href="http://www.usingmac.com/2008/4/28/safari-easy-private-browsing-toggling" rel="alternate" type="text/html"/>
    <title>Safari - Easy Private Browsing Toggling</title>
<summary type="html">&lt;p&gt;
It's quite surprising that when I open my MacBook today, I saw a globe instead of Apple logo. Anyone knows why?
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2279/2448044393_7cab360635_o.jpg&quot; width=&quot;250&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;Safari Private Browsing&lt;/h4&gt;

&lt;p&gt;
Ok. Let's talk about Private Browsing of Safari. We all know that with private browsing, whatever we browse won't come out at the History section of our Safari browser. It's quite a nice feature that Safari has.
&lt;/p&gt;</summary><content type="html">
            &lt;p&gt;
It's quite surprising that when I open my MacBook today, I saw a globe instead of Apple logo. Anyone knows why?
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2279/2448044393_7cab360635_o.jpg&quot; width=&quot;250&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;Safari Private Browsing&lt;/h4&gt;

&lt;p&gt;
Ok. Let's talk about Private Browsing of Safari. We all know that with private browsing, whatever we browse won't come out at the History section of our Safari browser. It's quite a nice feature that Safari has.
&lt;/p&gt;
&lt;p&gt;
However, it's quite unfortunate that the shortcut to activate/deactivate private browsing isn't available by default. Here is a way to assign a new shortcut to activate/deactivate private browsing. 
&lt;/p&gt;

&lt;h4&gt;Keyboard &amp; Mouse System Preferences&lt;/h4&gt;
&lt;p&gt;
Maybe you've already known that whenever you want to customize new keyboard shortcuts, you need to go into &lt;code&gt;Keyboard &amp; Mouse Preference Panes&lt;/code&gt;. After you've been inside this pane, go to the &lt;code&gt;Keyboard Shortcuts&lt;/code&gt; section.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2092/2448868248_81e52a873b_o.png&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;Add New Shortcuts&lt;/h4&gt;
&lt;p&gt;
You can see all the lists of available keyboard shortcuts here. Scroll down to the bottom of the list. If you've already assigned customized keyboard shortcuts for your Safari web browser before, you can see the label &lt;code&gt;Safari&lt;/code&gt; there.
&lt;/p&gt;

&lt;p&gt;
Highlight that line (Safari) and click on the &lt;code&gt;&quot;+&quot; button&lt;/code&gt; near the left bottom corner of the shortcuts' list. You should do new shortcut assignment two times and fill the pop-up pane like what are shown below.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3169/2448044571_25b8e6b96d_o.png&quot; /&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3066/2448044627_0e370910fe_o.png&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;Restart Safari and Try New Shortcut&lt;/h4&gt;
&lt;p&gt;
Now, you've finished assigning new shortcut to your Safari. You need to restart your Safari for the changes to take effect. When you press Fn+&lt;img src=&quot;/images/Command.jpg&quot; /&gt;+P, private browsing will be activated. If you press it for the second time, your Safari private browsing will be deactivated. Is it useful?
&lt;/p&gt;

&lt;h4&gt;A Little Side Effect&lt;/h4&gt;
&lt;p&gt;
You will see two Private Browsing options when you click on &lt;img src=&quot;/images/Apple.jpg&quot;&gt; ▸ Safari.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2257/2448868480_0b00cf3c23_o.png&quot; /&gt;
&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-04-10:3954</id>
    <published>2008-04-10T00:05:00Z</published>
    <updated>2008-04-10T00:19:03Z</updated>
    <category term="Tip and Tricks"/>
    <link href="http://www.usingmac.com/2008/4/10/add-spacers-to-leopard-os-x" rel="alternate" type="text/html"/>
    <title>Add spacers to Leopard OS X</title>
<content type="html">
            &lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3178/2402257520_aeced02f23_o.jpg&quot; height=&quot;107&quot; alt=&quot;leopardspaces&quot; width=&quot;359&quot; /&gt;
&lt;/p&gt;
&lt;p&gt;In Terminal.app, execute the command for number of times you want to create spacer.
&lt;/p&gt;
&lt;pre&gt;
defaults write com.apple.dock persistent-apps -array-add '{&quot;tile-type&quot;=&quot;spacer-tile&quot;;}'
&lt;/pre&gt;
&lt;p&gt;Then restart Dock. execute this command in Terminal.
&lt;/p&gt;
&lt;pre&gt;
killall Dock
&lt;/pre&gt;
&lt;p&gt;
Spacer can move with drag, can remove by context menu or drag outside. Another alternative, you also can download divider docks from &lt;a href=&quot;http://www.artofadambetts.com/archives/000046.html&quot;&gt;Dock Dividers&lt;/a&gt;.
&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-03-27:3153</id>
    <published>2008-03-27T05:14:00Z</published>
    <updated>2008-03-27T05:14:34Z</updated>
    <category term="Productivity"/>
    <category term="Tip and Tricks"/>
    <link href="http://www.usingmac.com/2008/3/27/display-hot-corners" rel="alternate" type="text/html"/>
    <title>Display - Hot Corners</title>
<summary type="html">&lt;p&gt;
In Tiger, Expose is very essential feature that most of Mac user need. Upgrading to Leopard, you also get the access to more Spaces. To use these great features easily, you could use Hot Corners.
&lt;/p&gt;

&lt;h4&gt;Hot Corners&lt;/h4&gt;
&lt;p&gt;
Hot corners help you activate one of those features whenever you move your mouse to the corner of the screen. And you can easily set up your hot corners. How to set up hot corners?
&lt;/p&gt;

&lt;h4&gt;Setting Hot Corners&lt;/h4&gt;
&lt;p&gt;
First of all, go inside &lt;img src=&quot;/images/Apple.jpg&quot; /&gt; ▸ System Preferences... Go to your search box, the one with magnifier at the left, and type in &quot;hot corner&quot; to look for this feature. You will see 2 items highlighted. Choosing either one has the same result.
&lt;/p&gt;</summary><content type="html">
            &lt;p&gt;
In Tiger, Expose is very essential feature that most of Mac user need. Upgrading to Leopard, you also get the access to more Spaces. To use these great features easily, you could use Hot Corners.
&lt;/p&gt;

&lt;h4&gt;Hot Corners&lt;/h4&gt;
&lt;p&gt;
Hot corners help you activate one of those features whenever you move your mouse to the corner of the screen. And you can easily set up your hot corners. How to set up hot corners?
&lt;/p&gt;

&lt;h4&gt;Setting Hot Corners&lt;/h4&gt;
&lt;p&gt;
First of all, go inside &lt;img src=&quot;/images/Apple.jpg&quot; /&gt; ▸ System Preferences... Go to your search box, the one with magnifier at the left, and type in &quot;hot corner&quot; to look for this feature. You will see 2 items highlighted. Choosing either one has the same result.
&lt;/p&gt;

&lt;h4&gt;Option 1. Via Desktop &amp; Screen Saver Preferences Pane&lt;/h4&gt;
&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2035/2365069665_331fe24e80_o.jpg&quot; /&gt;
&lt;/p&gt;
&lt;p&gt;
If you choose to set up your hot corners using through this pane, you can do the following :
&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Enter Desktop &amp; Screen Saver Preferences Pane&lt;/li&gt;
&lt;li&gt;
Click on the button labelled &quot;Hot Corners&quot;&lt;br /&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2403/2365069827_ee92c5d4f6_o.jpg&quot; width=&quot;300&quot; /&gt;
&lt;br /&gt;
&lt;/li&gt;
&lt;li&gt;
Additional menu will drop down. Here you can set up to four functions, each to one corner&lt;br /&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2299/2365902154_d901299446_o.jpg&quot; width=&quot;300&quot; /&gt;
&lt;br /&gt;
&lt;/li&gt;
&lt;li&gt;Confirm your changes by clicking the &quot;OK&quot; button&lt;/li&gt;
&lt;/ol&gt;

&lt;h4&gt;Option 2. Via Expose and Spaces Preferences Pane&lt;/h4&gt;
&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2150/2365902030_c9a4fe5d77_o.jpg&quot; /&gt;
&lt;/p&gt;
&lt;p&gt;
Using this pane is faster than the previous one. Unlike the previous one, you don't need to click on the button; Here you can directly assign the function of each corners.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2383/2365902214_fa6dc2be69_o.jpg&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;Tips. Avoiding Accidental Triggering&lt;/h4&gt;
&lt;p&gt;
You will be likely to encounter this issue using Hot Corners; You could accidentally move your mouse to the corner and activate the function assigned to that particular corner. Combining with modifier keys will help you solve this problem.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2100/2365070059_55ecf61746_o.jpg&quot; /&gt;
&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-03-18:2981</id>
    <published>2008-03-18T15:59:00Z</published>
    <updated>2008-03-18T16:42:24Z</updated>
    <category term="Screen Savers"/>
    <link href="http://www.usingmac.com/2008/3/18/screensaver-another-point-of-view" rel="alternate" type="text/html"/>
    <title>Screensaver - Another Point of View</title>
<summary type="html">&lt;p&gt;
Do you remember the most famous Mac Screensaver,&lt;br /&gt;
which is named Flurry?
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3278/2340324827_fb759235bc_o.jpg&quot; /&gt;
&lt;/p&gt;</summary><content type="html">
            &lt;p&gt;
Do you remember the most famous Mac Screensaver,&lt;br /&gt;
which is named Flurry?
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3278/2340324827_fb759235bc_o.jpg&quot; /&gt;
&lt;/p&gt;
&lt;p&gt;
With a little reflection from your Mac keyboard,&lt;br /&gt;
you can make it beautifully shines.
&lt;br /&gt;&lt;br /&gt;
&amp;lt;object height=&quot;350&quot; width=&quot;425&quot;&gt; &amp;lt;param name=&quot;movie&quot; value=&quot;http://www.youtube.com/v/AKa8WjTmJ5k&quot;&gt; &amp;lt;/param&gt; &amp;lt;embed type=&quot;application/x-shockwave-flash&quot; src=&quot;http://www.youtube.com/v/AKa8WjTmJ5k&quot; height=&quot;350&quot; width=&quot;425&quot;&gt; &amp;lt;/embed&gt; &amp;lt;/object&gt;
&lt;/p&gt;

&lt;p&gt;
Is it nice?
&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-03-16:2964</id>
    <published>2008-03-16T15:41:00Z</published>
    <updated>2008-03-17T16:50:38Z</updated>
    <category term="Application"/>
    <category term="Utilities"/>
    <link href="http://www.usingmac.com/2008/3/16/preview-tutorial-reading-pdf-files" rel="alternate" type="text/html"/>
    <title>Preview Tutorial - Reading PDF Files</title>
<summary type="html">&lt;h4&gt;Brief Introduction&lt;/h4&gt;
&lt;p&gt;
Somehow I feel it's quite difficult to read through many pages of PDF using my small display of MacBook. Fortunately, I come out with several ideas to improve the readability of reading PDF files with Preview which is our Mac default application to view PDF files.
&lt;/p&gt;


&lt;h4&gt;Setting Default Application&lt;/h4&gt;
&lt;p&gt;
Perhaps you haven't set up your default opening application for PDF file to Preview, you can do the following steps :
&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Highlight one of your collection of PDF Files&lt;/li&gt;
&lt;li&gt;Right click on it to show up the contextual menu&lt;/li&gt;
&lt;li&gt;Mouse over on &lt;code class=&quot;special-term&quot;&gt;Open With&lt;/code&gt; with modifier keys &lt;code&gt;Option(&lt;img src=&quot;/images/Option.jpg&quot; /&gt;)&lt;/code&gt; pressed. You should notice that the name is now changed to &lt;code class=&quot;special-term&quot;&gt;Always Open With&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Choose and Click on Preview&lt;/li&gt;
&lt;li&gt;Now, you've done setting up Preview as your default opening PDF Files as well as opening that highlighted file with Preview&lt;/li&gt;
&lt;/ol&gt;</summary><content type="html">
            &lt;h4&gt;Brief Introduction&lt;/h4&gt;
&lt;p&gt;
Somehow I feel it's quite difficult to read through many pages of PDF using my small display of MacBook. Fortunately, I come out with several ideas to improve the readability of reading PDF files with Preview which is our Mac default application to view PDF files.
&lt;/p&gt;


&lt;h4&gt;Setting Default Application&lt;/h4&gt;
&lt;p&gt;
Perhaps you haven't set up your default opening application for PDF file to Preview, you can do the following steps :
&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Highlight one of your collection of PDF Files&lt;/li&gt;
&lt;li&gt;Right click on it to show up the contextual menu&lt;/li&gt;
&lt;li&gt;Mouse over on &lt;code class=&quot;special-term&quot;&gt;Open With&lt;/code&gt; with modifier keys &lt;code&gt;Option(&lt;img src=&quot;/images/Option.jpg&quot; /&gt;)&lt;/code&gt; pressed. You should notice that the name is now changed to &lt;code class=&quot;special-term&quot;&gt;Always Open With&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Choose and Click on Preview&lt;/li&gt;
&lt;li&gt;Now, you've done setting up Preview as your default opening PDF Files as well as opening that highlighted file with Preview&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3169/2337041729_5bba36fda3_o.jpg&quot; /&gt;
&lt;/p&gt;


&lt;h4&gt;Adjusting Display Size&lt;/h4&gt;
&lt;p&gt;
For big monitor's owner, the view area wouldn't be much of trouble for you that you can easily &lt;code&gt;right-click&lt;/code&gt; on the display area and choose &lt;code class=&quot;special-term&quot;&gt;Automatically Resize&lt;/code&gt;. This will make your previewed page automatically zoomed to fit the entire view pane with its height and width proportional to the initial size.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2120/2337876776_8c82599b0d_o.jpg&quot; /&gt;
&lt;/p&gt;

&lt;p&gt;
Because the entire page is displayed on the view pane, you can easily jump to next page using your mouse-scroll or pressing Down-Arrow key.
&lt;/p&gt;

&lt;p&gt;
Problem arises when you need to view your long PDF File using small display of your MacBook. Suitable view will result it your Preview to have scroll bar on the right side of its view pane which causes the mouse-scroll and down-arrow key cannot be used to change to next page.
&lt;/p&gt;

&lt;p&gt;
Luckily, you can use Right-Arrow key instead. This can be used to switch to next page successfully. Note that using mouse-scroll or Down-Arrow can also change page but you're required to hit the end of page first.
&lt;/p&gt;

&lt;p&gt;
Hopefully, now you can get the convenient display and navigate easily. You can use &lt;code&gt;&lt;img src=&quot;/images/Command.jpg&quot; /&gt;+/-&lt;/code&gt; to zoom in/out followed by pressing the Zoom button (green button at top left corner of the pane) to adjust your view.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2201/2337042169_a850795214_o.jpg&quot; /&gt;
&lt;/p&gt;

&lt;h4&gt;Jump to Specific Page&lt;/h4&gt;
&lt;p&gt;
When you have hundreds pages of file, it will be really tedious to scroll down page by page to let say you want to reach page 145. You can use &lt;code class=&quot;special-term&quot;&gt;Go to Page.. &lt;img src=&quot;/images/Option.jpg&quot; /&gt;&lt;img src=&quot;/images/Command.jpg&quot; /&gt;G&lt;/code&gt; which is located under &lt;img src=&quot;/images/Apple.jpg&quot; /&gt; ▸ Go ▸ Go to Page.. Putting in the page number you want to look for and you'll be taken to the specified page.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2285/2337877122_498f6ef7c5_o.jpg&quot; /&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2304/2337877290_9ee82618ba_o.jpg&quot; /&gt;
&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-03-15:2939</id>
    <published>2008-03-15T06:45:00Z</published>
    <updated>2008-03-15T07:09:12Z</updated>
    <category term="Development"/>
    <category term="Leopard"/>
    <category term="UNIX and Open Source"/>
    <link href="http://www.usingmac.com/2008/3/15/developing-rails-application-on-mac-os-x-leopard" rel="alternate" type="text/html"/>
    <title>Developing Rails Application on Mac OS X Leopard</title>
<summary type="html">&lt;p&gt;
With Ruby on Rails you can build powerful and dynamic web sites. Read this article to learn how to develop your application using Xcode 3.0 and the tools that come pre-installed in Leopard. 	
&lt;/p&gt;

&lt;p&gt; &lt;a href=&quot;http://www.rubyonrails.org&quot;&gt;Ruby on Rails&lt;/a&gt; is a popular and powerful open source web framework 
for rapidly creating high-quality web applications. Rails is thriving on Mac OS X,  and Leopard comes pre-installed
with Ruby, Rails, Mongrel, Capistrano, Subversion, and other tools that help to
streamline the development and deployment of Rails applications. We will use
the Organizer feature of XCode 3.0 to demo the step of the development.
&lt;/p&gt;

&lt;p&gt;
This article gives you a full tour of &lt;a href=&quot;http://weblog.rubyonrails.org/2007/12/7/rails-2-0-it-s-done&quot;&gt;Ruby on Rails 2.0&lt;/a&gt; on
Mac OS X Leopard and building a web application using the latest Rails
features with Xcode 3.0.
&lt;/p&gt;</summary><content type="html">
            &lt;p&gt;
With Ruby on Rails you can build powerful and dynamic web sites. Read this article to learn how to develop your application using Xcode 3.0 and the tools that come pre-installed in Leopard. 	
&lt;/p&gt;

&lt;p&gt; &lt;a href=&quot;http://www.rubyonrails.org&quot;&gt;Ruby on Rails&lt;/a&gt; is a popular and powerful open source web framework 
for rapidly creating high-quality web applications. Rails is thriving on Mac OS X,  and Leopard comes pre-installed
with Ruby, Rails, Mongrel, Capistrano, Subversion, and other tools that help to
streamline the development and deployment of Rails applications. We will use
the Organizer feature of XCode 3.0 to demo the step of the development.
&lt;/p&gt;

&lt;p&gt;
This article gives you a full tour of &lt;a href=&quot;http://weblog.rubyonrails.org/2007/12/7/rails-2-0-it-s-done&quot;&gt;Ruby on Rails 2.0&lt;/a&gt; on
Mac OS X Leopard and building a web application using the latest Rails
features with Xcode 3.0.
&lt;/p&gt;
&lt;h2&gt;Ruby, Rails, and Leopard&lt;/h2&gt;

&lt;p&gt;
In Leopard, Ruby and Rails are pre-installed abundle with of other useful RubyGems. 
By default, you get Ruby version 1.8.6 and Rails version 1.2.6, the latest
stable releases at the time Leopard shipped. Ruby releases are few and far
between (it's still at 1.8.6), but Rails has frequent new releases. In fact,
the application we'll build requires Rails 2.0.2. The good news is it's easy
to upgrade Rails and RubyGems. Make sure your system is up to date now by
running these commands:
&lt;/p&gt;

&lt;pre&gt; sudo gem update --system
 sudo gem install rails
 sudo gem update rake
 sudo gem update sqlite3-ruby
&lt;/pre&gt;

&lt;p&gt;Do the command below too, to check your version of ruby and rails: &lt;/p&gt;

&lt;pre&gt;
	ruby -v
	ruby 1.8.6 (2007-09-24 patchlevel 111) [i686-darwin9.1.0]
	
	rails -v
	Rails 2.0.2
&lt;/pre&gt;

&lt;p&gt;
The first command updates the RubyGems system itself, which is required by the
latest version of Rails. The second command updates Rails-specific gems and
installs any new components (specifically Active Resource). The third command
updates Rake, the &lt;tt&gt;make&lt;/tt&gt;-like build tool used by Rails. Finally, the
last command updates the Ruby bindings for the SQLite3 database. Running all
these commands may take a while. When it's finished, you can list all the
installed gems by typing
&lt;/p&gt;

&lt;pre&gt; gem list --local

&lt;/pre&gt;

&lt;p&gt;
If you've used Ruby before, you may be interested to know where the Ruby
gems live in Leopard. The answer is in two places:
&lt;/p&gt;

&lt;pre&gt;/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8 
/Library/Ruby/Gems/1.8
&lt;/pre&gt;

&lt;p&gt;
The &lt;tt&gt;/System&lt;/tt&gt; repository is where all the pre-installed gems live,
while the &lt;tt&gt;/Library&lt;/tt&gt; repository is empty by default. When you install
new gems, they'll end up in the &lt;tt&gt;/Library&lt;/tt&gt; repository. Thankfully, it's
all transparent.

&lt;/p&gt;

&lt;h2&gt;Creating a New Rails Application&lt;/h2&gt;

&lt;p&gt;
&lt;i&gt;
Note: This tutorial uses Rails version 2.0.2. With future Rails updates, some of the functionality described in this article may change.
&lt;/i&gt;
&lt;/p&gt;

&lt;p&gt;
Let's say, for example, that we have a club that organizes fund-raising events. When we
put on an event we incur expenses from vendors who provide goods and services.
Our club operates on a fairly tight budget, so we need to make sure expenses
are in line with the budget for each event. The old paper and pencil system
broke down last month and we've decided to replace it with an online expense
tracking application that everyone can share.
&lt;/p&gt;

&lt;p&gt;
First we need to create the application. All Rails applications have a
consistent directory structure so that Rails can find stuff without needing to
be told where to look. In a directory of your choosing (e.g., your home directory), create a skeleton application directory structure and a set of files
for our expenses application by typing

&lt;/p&gt;

&lt;pre&gt; rails expenses&lt;/pre&gt;

&lt;p&gt;
That command generates a number of directories and files in an
&lt;tt&gt;expenses&lt;/tt&gt; directory. We'll be editing various files as we go, and to
streamline your development workflow you'll want quick access to frequently
used files. Xcode 3.0 in Leopard has an Organizer feature that makes it easy
to navigate around Rails projects. You don't even need to create a new Xcode
project.
&lt;/p&gt;

&lt;p&gt;
Follow these steps to open the Rails application in the Organizer:
&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;
    &lt;p&gt;
      Launch Xcode and choose &quot;Window &amp;gt; Organizer&quot;. An empty
      Organizer window appears.
    &lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;
      Drag your &lt;tt&gt;expenses&lt;/tt&gt; directory from a Finder window into the
      Organizer window.
    &lt;/p&gt;

  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;
      Click the disclosure triangle next to the top-level &lt;tt&gt;expenses&lt;/tt&gt; directory to display its contents.
    &lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;

      Drill down into the &lt;tt&gt;app/controllers&lt;/tt&gt; directory and select
      the &lt;tt&gt;application.rb&lt;/tt&gt; file.
    &lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;
       Display the text editor pane by clicking the rectangle icon in the
       bottom-left corner of the Organizer.
    &lt;/p&gt;

  &lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;
In the Organizer window, shown in Figure 1, you should see the files and
directories that the &lt;tt&gt;rails&lt;/tt&gt; command created. You'll notice in the
Organizer that you have familiar Xcode editing features such as syntax
coloring, code folding, line numbers, method shortcuts, and so on. 
&lt;/p&gt;

&lt;img src=&quot;http://farm4.static.flickr.com/3154/2333843159_5d7a9173b7.jpg&quot; height=&quot;300&quot; alt=&quot;Organizer-1&quot; width=&quot;500&quot; /&gt;&lt;br&gt;
&lt;p class=&quot;smalltext&quot;&gt;
  &lt;strong&gt;Figure 1:&lt;/strong&gt;

  Xcode 3.0 Organizer showing the Rails application directory structure
&lt;/p&gt;

&lt;p&gt;
At this point, we could go ahead and fire up our &lt;tt&gt;expenses&lt;/tt&gt; application from a Terminal command line using the &lt;tt&gt;script/server&lt;/tt&gt; command.  However, 
in addition to giving you a central place to edit files, the Xcode Organizer also lets you assign actions to folders.  So rather than running the Rails application in a separate Terminal window, we'll assign an action to run it straight from the Organizer.  
&lt;/p&gt;

&lt;p&gt;
Follow these steps to create a new Organizer Action to run the Rails application:
&lt;/p&gt;

&lt;ol&gt;
  &lt;li&gt;
    &lt;p&gt;
      Select the top-level &lt;tt&gt;expenses&lt;/tt&gt; folder.  
    &lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;

      Click and hold the Run toolbar item until a pop-up menu appears.
      Choose &quot;Edit Actions...&quot; and you should see the Action Editor
      as shown in Figure 2.
    &lt;/p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2270/2333843229_1d5727a04a.jpg&quot; height=&quot;302&quot; alt=&quot;Organizer-2&quot; width=&quot;500&quot; /&gt;&lt;br&gt;
    &lt;p class=&quot;smalltext&quot;&gt;
      &lt;strong&gt;Figure 2:&lt;/strong&gt;
      Xcode 3.0 Organizer Action Editor
    &lt;/p&gt;
    &lt;p&gt;

      The list on the left side of the Action Editor displays actions
      associated with the Run toolbar item, along with their with optional
      shortcut keys. On the right side is a drop-down directory specifier and
      a script editor.
    &lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;
      Add a new Shell Script Action using the add button (+) in the
      bottom-left corner of the Organizer.
      Name the action &quot;start server&quot; by double-clicking on the
      default name &quot;Shell Script&quot;. 
    &lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;

      Set the directory to
      &quot;Top Level Organizer Item&quot;. This indicates that the action's
      command should be run from the top-level folder (&lt;tt&gt;expenses&lt;/tt&gt;),
      regardless of the folder that's currently selected when the action is
      run.
    &lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;
      Change the command to &quot;script/server&quot; and clear out the 
      arguments.
    &lt;/p&gt;
    &lt;p&gt;
      The Action Editor should now look like the one shown in Figure 3.
    &lt;/p&gt;

&lt;img src=&quot;http://farm4.static.flickr.com/3015/2334671284_f386c4c009.jpg&quot; height=&quot;297&quot; alt=&quot;Organizer-3&quot; width=&quot;500&quot; /&gt;    &lt;br&gt;
    &lt;p class=&quot;smalltext&quot;&gt;
      &lt;strong&gt;Figure 3:&lt;/strong&gt;
      Adding a new Organizer Action
    &lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;

      Click &quot;OK&quot; to save the new action.
    &lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;p&gt;
      Back in the Organizer window, select the &lt;tt&gt;expenses&lt;/tt&gt; folder, then
      click and hold the Run toolbar item. When the pop-up menu appears,
      choose the &quot;start server&quot; action. (Or just click the Run
      button and it'll run that action since there's only one assigned
      action.) 
    &lt;/p&gt;
    &lt;p&gt;

      A Debugger window opens and starts the server with output similiar
      to the output shown in Figure 4.
    &lt;/p&gt;
&lt;img src=&quot;http://farm4.static.flickr.com/3290/2334671456_fabf0ac695.jpg&quot; height=&quot;239&quot; alt=&quot;Organizer-4&quot; width=&quot;500&quot; /&gt;    &lt;br&gt;
    &lt;p class=&quot;smalltext&quot;&gt;
      &lt;strong&gt;Figure 4:&lt;/strong&gt;
      Running an Organizer Action
    &lt;/p&gt;
  &lt;/li&gt;

  &lt;li&gt;
    &lt;p&gt;
    Now point Safari at &lt;a href=&quot;http://localhost:3000&quot;&gt;http://localhost:3000&lt;/a&gt;. You should see a
    web page welcoming you aboard Rails.
    &lt;/p&gt;
  &lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;
So far,  we've stood up a brand new application and we're organized, but it
doesn't help our fund-raising campaign. Let's fix that.
&lt;/p&gt;

&lt;h2&gt;Jump-Starting the Application&lt;/h2&gt;

&lt;p&gt;
Now we're ready to put some meat on the bones of the skeleton directory
structure. For starters, we need a web interface for creating some events in
the database. An event is simply a name and a budgeted amount. The fastest way
to put up a web interface backed by a database is by using what Rails calls
&lt;i&gt;scaffolding&lt;/i&gt;. Scaffolding is the initial supporting code that handles
the basic create, read, update, and delete &lt;a href=&quot;http://en.wikipedia.org/wiki/Create,_read,_update_and_delete&quot;&gt;(CRUD)&lt;/a&gt; operations of any
database-backed web application.
&lt;/p&gt;

&lt;p&gt;
Open a Terminal window, then change directory to the &lt;tt&gt;expenses&lt;/tt&gt;
directory and create the event scaffolding by typing

&lt;/p&gt;

&lt;pre&gt; script/generate scaffold event name:string budget:decimal
&lt;/pre&gt;

&lt;p&gt;
This single command generates all the Ruby code we need to start administering
events:
&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt; 
    &lt;p&gt;
      &lt;i&gt;Model&lt;/i&gt;: An &lt;tt&gt;Event&lt;/tt&gt; model class in the
      &lt;tt&gt;app/models/event.rb&lt;/tt&gt; file
    &lt;/p&gt;

  &lt;/li&gt;
  &lt;li&gt; 
    &lt;p&gt;    
      &lt;i&gt;View&lt;/i&gt;: View template files in the &lt;tt&gt;app/views/events&lt;/tt&gt;
      directory for listing, showing, creating, and editing events
    &lt;/p&gt;
  &lt;/li&gt;
  &lt;li&gt; 
    &lt;p&gt; 
      &lt;i&gt;Controller&lt;/i&gt;: An &lt;tt&gt;EventsController&lt;/tt&gt; class in the
      &lt;tt&gt;app/controllers/expenses_controller.rb&lt;/tt&gt; file
    &lt;/p&gt;

  &lt;/li&gt;
  &lt;li&gt; 
    &lt;p&gt;    
      &lt;i&gt;Database Migration&lt;/i&gt;: A &lt;tt&gt;CreateEvents&lt;/tt&gt; class in the 
      &lt;tt&gt;db/migrate/001_create_events.rb&lt;/tt&gt; file that when run
      creates an &lt;tt&gt;events&lt;/tt&gt; database table with three columns:
      &lt;tt&gt;id&lt;/tt&gt;, &lt;tt&gt;name&lt;/tt&gt;, and &lt;tt&gt;budget&lt;/tt&gt; 
    &lt;/p&gt;

  &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;
We'll look at these files in more detail shortly. All we need to do now is
apply the database migration to create the &lt;tt&gt;events&lt;/tt&gt; database table so
we can start creating events. Rails applications use Rake (Ruby's equivalent
of Make) to automate recurring tasks such as applying migrations. We could run
&lt;tt&gt;rake db:migrate&lt;/tt&gt; from a Terminal command line, but again the Organizer
makes this easier. All the Rake tasks are already available as pre-configured
actions.
&lt;/p&gt;

&lt;p&gt;
Click and hold the Action toolbar item, then choose the &quot;db:migrate&quot;
action (the first one). A window opens showing the results of applying the
migration, as shown in Figure 5.
&lt;/p&gt;

&lt;img src=&quot;http://farm3.static.flickr.com/2274/2333843549_34b0b08bd1.jpg&quot; height=&quot;163&quot; alt=&quot;Organizer-5&quot; width=&quot;500&quot; /&gt;&lt;br&gt;
&lt;p class=&quot;smalltext&quot;&gt;
  &lt;strong&gt;Figure 5:&lt;/strong&gt;
  Applying the events database migration
&lt;/p&gt;

&lt;p&gt;
Let's see how close scaffolding gets us to a web interface for administering
events. Point Safari at &lt;a href=&quot;http://localhost:3000/events&quot;&gt;http://localhost:3000/events&lt;/a&gt;. You
should see a web page that lets you create new events.
&lt;/p&gt;

&lt;p&gt;
Go ahead: create an event and the new event will show up in the event listing.
From there you can show, edit, or delete the event. Figure 6 shows example
events for our fund-raising campaign.
&lt;/p&gt;

&lt;img src=&quot;http://farm3.static.flickr.com/2278/2333850741_eb24ce1aa2_o.jpg&quot; height=&quot;204&quot; alt=&quot;ListingEvents&quot; width=&quot;362&quot; /&gt;
&lt;p class=&quot;smalltext&quot;&gt;
  &lt;strong&gt;Figure 6:&lt;/strong&gt;
  Using scaffolding to administer events
&lt;/p&gt;

&lt;p&gt;
That takes care of event management. Now let's repeat the cycle to put up a
web interface for administering vendors. Generate the vendor scaffolding by
typing
&lt;/p&gt;

&lt;pre&gt; script/generate scaffold vendor name:string email:string
&lt;/pre&gt;

&lt;p&gt;
This command generates all the supporting code for a vendor web interface,
including a database migration in the
&lt;tt&gt;db/migrate/002_create_vendors.rb&lt;/tt&gt; file. 
&lt;/p&gt;

&lt;p&gt;
Apply the new migration to update the database schema to include the
&lt;tt&gt;vendors&lt;/tt&gt; table by choosing the &quot;db:migrate&quot; action from the
Action toolbar item. The results are shown in Figure 7.
&lt;/p&gt;

&lt;img src=&quot;http://farm4.static.flickr.com/3046/2333843591_957b9c2d91.jpg&quot; height=&quot;163&quot; alt=&quot;Organizer-6&quot; width=&quot;500&quot; /&gt;
&lt;br&gt;
&lt;p class=&quot;smalltext&quot;&gt;
  &lt;strong&gt;Figure 7:&lt;/strong&gt;
  Applying the vendors database migration
&lt;/p&gt;

&lt;p&gt;
Then point Safari at &lt;a href=&quot;http://localhost:3000/vendors&quot;&gt;http://localhost:3000/vendors&lt;/a&gt;. You
should see a web page that lets you create new vendors.
&lt;/p&gt;

&lt;p&gt;  To recap: In a very short amount of time, and with no explicit configuration,
we've created a database-backed web application to CRUD (the verb form) events
and vendors. It  won't win any web design awards, but it's functional
and gives us a jump-start on our application.
&lt;/p&gt;

&lt;h2&gt;How It Works&lt;/h2&gt;

&lt;p&gt;
Looking at the code generated by the &lt;tt&gt;script/generate scaffold&lt;/tt&gt; command is a great way to learn how Rails
applications work. After all, the templates used by the generator were written
by the Rails core team. And as we'll see a bit later, scaffold-generated code
serves merely as an exemplar that should be tweaked as necessary for your
application.
&lt;/p&gt;

&lt;p&gt;
Let's follow a request through the request/response cycle, looking inside the
scaffold-generated code as we go to see how all the components work together.
Figure 8 shows the MVC components in play for events, and their file
equivalents.
&lt;/p&gt;

&lt;img src=&quot;http://farm4.static.flickr.com/3288/2333843631_a413ff9016.jpg&quot; height=&quot;250&quot; alt=&quot;LeopardMVC&quot; width=&quot;500&quot; /&gt;
&lt;p class=&quot;smalltext&quot;&gt;
  &lt;strong&gt;Figure 8:&lt;/strong&gt;
  MVC components and their files
&lt;/p&gt;



&lt;h3&gt;RESTful Conventions&lt;/h3&gt;

&lt;p&gt;
The speed at which we were able to create a fully-functioning web application
can be credited in large part to conventions. Rails relies heavily on
conventions to eliminate most configuration, thus making web developers a lot
happier.

&lt;/p&gt;

&lt;p&gt;
Take, for example, the &quot;Show&quot; hyperlink for an event. In the
&lt;tt&gt;app/views/events/index.html.erb&lt;/tt&gt; template, the hyperlink is generated
using
&lt;/p&gt;

&lt;pre&gt;&amp;lt;%= link_to 'Show', event %&amp;gt;
&lt;/pre&gt;

&lt;p&gt;
That line of code generates the following HTML, for example:
&lt;/p&gt;

&lt;pre&gt;&amp;lt;a href=&quot;/events/1&quot;&amp;gt;Show&amp;lt;/a&amp;gt;
&lt;/pre&gt;

&lt;p&gt;
When this hyperlink is clicked in Safari, it ends up executing Ruby code
inside the Rails application. But how does Rails know how to route an incoming
URL to the appropriate code that handles the request? The answer: conventions.
&lt;/p&gt;

&lt;p&gt;
It turns out that the HTTP protocol already has conventions for interacting
with resources on the web via a simple set of verbs: &lt;tt&gt;GET&lt;/tt&gt;,
&lt;tt&gt;POST&lt;/tt&gt;, &lt;tt&gt;PUT&lt;/tt&gt;, &lt;tt&gt;DELETE&lt;/tt&gt;, etc. With every HTTP request
comes one of these verbs. The URL identifies the &lt;i&gt;resource&lt;/i&gt; (the noun,
if you will). For example, clicking the &lt;a href=&quot;http://localhost:3000/events/1&quot;&gt;http://localhost:3000/events/1&lt;/a&gt; link
issues a &lt;tt&gt;GET&lt;/tt&gt; request for the event living at that web address.

&lt;/p&gt;

&lt;p&gt;
This resource-oriented approach to web design is an example of the &lt;a href=&quot;http://en.wikipedia.org/wiki/Representational_State_Transfer&quot;&gt;REST
architectural style&lt;/a&gt;, and Rails has whole-heartedly embraced it. Now, REST is a
relatively complex (and academic) topic that's beyond the scope of this
article. Thankfully you don't have to be a REST expert to use Rails. You just
need to tell Rails which resources should be accessible via the RESTful
conventions. Rails then takes care of routing incoming HTTP verbs and URLs to
those resources.
&lt;/p&gt;

&lt;p&gt;
When we ran the scaffold generator for events, for example, Rails
assumed that events are resources we want to expose via RESTful
conventions.  The same is true for vendors.  So if you look in the
&lt;tt&gt;config/routes.rb&lt;/tt&gt; file you'll see that the following lines were
automatically added:
&lt;/p&gt;

&lt;pre&gt;map.resources :events 
map.resources :vendors
&lt;/pre&gt;

&lt;p&gt;
Those two lines of code dynamically add &lt;i&gt;routes&lt;/i&gt; for accessing our events
and vendors according to the RESTful conventions. To see all the routes,
choose the &quot;routes&quot; action from the Action toolbar item.
&lt;/p&gt;

&lt;p&gt; 
Let's look at just a few of the routes in the list you'll see to get a glimpse
of what's going on behind the scenes:
&lt;/p&gt;

&lt;pre&gt;events GET  /events {:controller =&amp;gt; &quot;events&quot;, :action =&amp;gt; &quot;index&quot;} 
       POST /events {:controller =&amp;gt; &quot;events&quot;, :action =&amp;gt; &quot;create&quot;} 
  
event  GET /events/:id {:controller =&amp;gt; &quot;events&quot;, :action =&amp;gt; &quot;show&quot;} 
       PUT /events/:id {:controller =&amp;gt; &quot;events&quot;, :action =&amp;gt; &quot;update&quot;} 

&lt;/pre&gt;

&lt;p&gt;
In a nutshell, the &lt;code&gt;map.resources&lt;/code&gt; line generates routes into our
application using both the incoming HTTP verb and URL. For example, to list
all the events we'd send in the URL &lt;code&gt;/events&lt;/code&gt;. The exact same incoming
URL is used to create a new event. The only difference is the HTTP verb that is
used: GET is a read-only operation that lists the events and POST is a write
operation that creates a new event. To show or update an existing event, the
URL needs to include the event id (primary key), for example
&lt;code&gt;/events/1&lt;/code&gt;. Again, the URL is the same, but the HTTP verb is
different: GET fetches the event and PUT updates the event.
&lt;/p&gt;

&lt;h3&gt;Controllers&lt;/h3&gt;

&lt;p&gt;

Now let's follow the request back into scaffold-generated MVC code. When Rails
receives a &lt;code&gt;GET&lt;/code&gt; request for the &lt;code&gt;/events/1&lt;/code&gt; resource, for
example, it invokes the &lt;code&gt;show&lt;/code&gt; method (called an &lt;i&gt;action&lt;/i&gt;) of the
&lt;code&gt;EventsController&lt;/code&gt;. That action is found in the
&lt;code&gt;app/controllers/events_controller.rb&lt;/code&gt; file.

&lt;/p&gt;

&lt;pre&gt;class EventsController &amp;lt; ApplicationController
  
  def show
    @event = Event.find(params[:id])
    
    respond_to do |format|
      format.html # renders show.html.erb
      format.xml  { render :xml =&amp;gt; @event }
    end
  end
  
  # plus other action methods for listing, creating, 
  # updating, and deleting events
end
&lt;/pre&gt;

&lt;p&gt;
The &lt;code&gt;show&lt;/code&gt; action uses the event id supplied in &lt;code&gt;params[:id]&lt;/code&gt; (1, in this case) to
find a matching event in the &lt;code&gt;events&lt;/code&gt; database table. It then populates
an &lt;code&gt;Event&lt;/code&gt; model object with the values corresponding to that database
table row. The resulting &lt;code&gt;Event&lt;/code&gt; model object is assigned to the

&lt;code&gt;@event&lt;/code&gt; instance variable. (Ruby identifies instance variables as
variables starting with an &lt;code&gt;@&lt;/code&gt; symbol.) 
&lt;/p&gt;

&lt;h3&gt;Models&lt;/h3&gt;

&lt;p&gt;
The &lt;code&gt;Event&lt;/code&gt; model class itself lives in the
&lt;code&gt;app/models/event.rb&lt;/code&gt; file.

&lt;/p&gt;

&lt;pre&gt;class Event &amp;lt; ActiveRecord::Base
end
&lt;/pre&gt;

&lt;p&gt;
At first glance, this class appears to do nothing, but in fact it already has
a lot of functionality inherited through its &lt;code&gt;ActiveRecord::Base&lt;/code&gt;
parent class. &lt;code&gt;ActiveRecord&lt;/code&gt; is a component of Rails that, among other
things, uses reflection and naming conventions to transparently map relational
database tables into models. By convention, the &lt;code&gt;Event&lt;/code&gt; model
encapsulates access to the &lt;code&gt;events&lt;/code&gt; table in our database. An instance
of an &lt;code&gt;Event&lt;/code&gt; model represents a row in the &lt;code&gt;events&lt;/code&gt;

table, with each table column mapping to an attribute of the &lt;code&gt;Event&lt;/code&gt;
instance. 
&lt;/p&gt;

&lt;p&gt;
For example, without any additional configuration or code, inside of
the &lt;code&gt;show&lt;/code&gt; action we could get the name of the event using:
&lt;/p&gt;

&lt;pre&gt;@event.name
&lt;/pre&gt;

&lt;h3&gt;Database Migrations&lt;/h3&gt;

&lt;p&gt;
Now you may be wondering which database Rails is using and how it got
connected. When we created the application, a &lt;code&gt;config/database.yml&lt;/code&gt;
file was generated. In that file you'll notice that Rails has pre-configured
three database connections—&lt;code&gt;development&lt;/code&gt;, &lt;code&gt;test&lt;/code&gt;, and
&lt;code&gt;production&lt;/code&gt;—that correspond to three runtime environments. 
&lt;/p&gt;

&lt;p&gt;
We're doing development now (the default environment), so have a look at that
particular section of the &lt;code&gt;config/database.yml&lt;/code&gt; file.

&lt;/p&gt;

&lt;pre&gt;development:
  adapter: sqlite3
  database: db/development.sqlite3
  timeout: 5000
&lt;/pre&gt;

&lt;p&gt;
Rails configures a SQLite3 database by default, which is quite handy given
that SQLite3 is already installed on Leopard. When it comes time to deploy this
application, we'll switch over to a MySQL database running on Leopard Server.
&lt;/p&gt;

&lt;p&gt;
When we ran the first database migration to create the &lt;code&gt;events&lt;/code&gt; table,
the &lt;code&gt;db/development.sqlite3&lt;/code&gt; database was automatically created. Here's
what the &lt;code&gt;db/migrate/001_create_events.rb&lt;/code&gt; file looks like:

&lt;/p&gt;

&lt;pre&gt;class CreateEvents &amp;lt; ActiveRecord::Migration
  def self.up
    create_table :events do |t|
      t.string :name
      t.decimal :budget

      t.timestamps
    end
  end

  def self.down
    drop_table :events
  end
end
&lt;/pre&gt;

&lt;p&gt;
Migrations give us a way to evolve our database schema and data over time in a
repeatable, automated way. Each migration defines two class-level methods:
&lt;code&gt;up&lt;/code&gt; and &lt;code&gt;down&lt;/code&gt;. The &lt;code&gt;up&lt;/code&gt; method moves the migration
&quot;forward&quot;, in this case by creating the &lt;code&gt;events&lt;/code&gt; table and
its columns. Note that &lt;code&gt;create_table&lt;/code&gt; will implicitly create a primary
key column called &lt;code&gt;id&lt;/code&gt; by default. 

&lt;/p&gt;

&lt;p&gt;
The &lt;code&gt;down&lt;/code&gt; method rolls the migration &quot;backward&quot;, in this
case by dropping the &lt;code&gt;events&lt;/code&gt; table. That is, migrations are
reversible. For example, if you wanted to drop the &lt;code&gt;events&lt;/code&gt; table,
you'd type '&lt;code&gt;rake db:rollback&lt;/code&gt;'.
&lt;/p&gt;

&lt;h3&gt;Views&lt;/h3&gt;

&lt;p&gt;
Back in the &lt;code&gt;show&lt;/code&gt; action, we've fetched the event from the database
and now it's time to show it. The &lt;code&gt;respond_to&lt;/code&gt; block decides how to
render the event depending on the format requested by the client. Since we're
using Safari as the client (and we haven't explicitely specified a format),
the format will be HTML. So in this case, the &lt;code&gt;show&lt;/code&gt; action renders the
template found in the &lt;code&gt;app/views/events/show.html.erb&lt;/code&gt; file.

&lt;/p&gt;

&lt;pre&gt;&amp;lt;p&amp;gt;
  &amp;lt;b&amp;gt;Name:&amp;lt;/b&amp;gt;
  &amp;lt;%= h @event.name %&amp;gt;
&amp;lt;/p&amp;gt;

&amp;lt;p&amp;gt;

  &amp;lt;b&amp;gt;Budget:&amp;lt;/b&amp;gt;
  &amp;lt;%= h @event.budget %&amp;gt;
&amp;lt;/p&amp;gt;

&amp;lt;%= link_to 'Edit', edit_event_path(@event) %&amp;gt; |
&amp;lt;%= link_to 'Back', events_path %&amp;gt;
&lt;/pre&gt;

&lt;p&gt;
Rails view templates are a mix of HTML and Ruby code. Any expression between
&lt;code&gt;&amp;lt;%=&lt;/code&gt; and &lt;code&gt;%&amp;gt;&lt;/code&gt; is evaluated as Ruby code and the result is
substituted back into the response. Notice that the &lt;code&gt;show&lt;/code&gt; template has
access to the &lt;code&gt;@event&lt;/code&gt; instance variable that was created in the
&lt;code&gt;show&lt;/code&gt; action of the &lt;code&gt;EventsController&lt;/code&gt;. Using the

&lt;code&gt;@event&lt;/code&gt; variable, the &lt;code&gt;show&lt;/code&gt; template simply outputs the value
of each event attribute with its associated column name.
&lt;/p&gt;

&lt;p&gt;
The template then generates hyperlinks to the &lt;code&gt;edit&lt;/code&gt; and &lt;code&gt;index&lt;/code&gt;
actions using the &lt;code&gt;link_to&lt;/code&gt; helper. The &lt;code&gt;edit_event_path&lt;/code&gt; and

&lt;code&gt;events_path&lt;/code&gt; methods were generated by the &lt;code&gt;map.resources
:events&lt;/code&gt; declaration we saw previously. They create URLs according to the
RESTful conventions that route back into the application.
&lt;/p&gt;

&lt;p&gt;
At this point we've followed one HTTP request through the scaffold-generated
code to generate an HTML page as the response. Now let's start adding some
code of our own.
&lt;/p&gt;

&lt;h2&gt;Validating Models&lt;/h2&gt;

&lt;p&gt;
You may have noticed that the scaffold-generated web form used to create and
edit events will let you enter anything in the fields, and even let you leave
required fields blank.  That's no good—we only want valid data in our database.

&lt;/p&gt;

&lt;p&gt;
Maintaining the consistency of the application's data is a model's job. Rails
includes a rich set of built-in model validations and it's easy to write your
own, as well. So let's add some model validations to ensure an event has a
name and a valid budget amount.
&lt;/p&gt;

&lt;p&gt;
Update the &lt;code&gt;app/models/event.rb&lt;/code&gt; file as follows:
&lt;/p&gt;

&lt;pre&gt;class Event &amp;lt; ActiveRecord::Base
  validates_presence_of :name
  validates_numericality_of :budget, :greater_than =&amp;gt; 0.0
end

&lt;/pre&gt;

&lt;p&gt;
Now try to create an event with a blank name or invalid budget amount. You
should see something similar to the web form shown in Figure 9.
&lt;/p&gt;

&lt;img src=&quot;http://farm3.static.flickr.com/2029/2334671628_9ece22d207_o.jpg&quot; height=&quot;415&quot; alt=&quot;LeopardValidations&quot; width=&quot;438&quot; /&gt;
&lt;p class=&quot;smalltext&quot;&gt;
  &lt;strong&gt;Figure 9:&lt;/strong&gt;
  Model validations at work
&lt;/p&gt;

&lt;h2&gt;Linking Models Together&lt;/h2&gt;

&lt;p&gt;
Administering events and vendors is a good start, but we're still missing the
ability to track expenditures. An expense is simply an amount charged by a
vendor for an event. In database terms that means an expense needs to have
foreign keys pointing to its event and vendor. In other words, an expense
joins together an event and a vendor. The database schema we're aiming for is
shown in Figure 10.
&lt;/p&gt;

&lt;img src=&quot;http://farm3.static.flickr.com/2116/2333843745_27df4348a2.jpg&quot; height=&quot;168&quot; alt=&quot;Schema&quot; width=&quot;500&quot; /&gt;
&lt;p class=&quot;smalltext&quot;&gt;
  &lt;strong&gt;Figure 10:&lt;/strong&gt;
  Many-to-many association database schema
&lt;/p&gt;


&lt;p&gt;
Just like event and vendor, we want an expense to be a resource. The only
difference is we don't need a full scaffold-generated web interface for
expenses. Instead, we're going to record expenses using our existing events
web interface. However, we still need a migration, a model, and a controller
for expenses.

&lt;/p&gt;

&lt;p&gt;
Generate a new &lt;code&gt;expense&lt;/code&gt; resource by typing:
&lt;/p&gt;

&lt;pre&gt; script/generate resource expense event_id:integer vendor_id:integer amount:decimal 
&lt;/pre&gt;

&lt;p&gt;
Naming is important here. Rails assumes that the &lt;code&gt;event_id&lt;/code&gt; foreign key
column references the &lt;code&gt;id&lt;/code&gt; column of the &lt;code&gt;events&lt;/code&gt; table, and
likewise &lt;code&gt;vendor_id&lt;/code&gt; references the &lt;code&gt;id&lt;/code&gt; column of the

&lt;code&gt;vendors&lt;/code&gt; table. It's yet another example of how Rails uses naming
conventions to keep external configuration at a minimum.  (You can always
override the default behavior.)
&lt;/p&gt;

&lt;p&gt;
Then apply the migration that was generated in the
&lt;code&gt;db/migrate/003_create_expenses.rb&lt;/code&gt; file to create the
&lt;code&gt;expenses&lt;/code&gt; database table by choosing the &quot;db:migrate&quot; action
from the Action toolbar item.  The results are shown in Figure 11:
&lt;/p&gt;

&lt;img src=&quot;http://farm3.static.flickr.com/2023/2334671702_2515800acf.jpg&quot; height=&quot;162&quot; alt=&quot;Organizer-7&quot; width=&quot;500&quot; /&gt;
&lt;br&gt;

&lt;p class=&quot;smalltext&quot;&gt;
  &lt;strong&gt;Figure 11:&lt;/strong&gt;
  Applying the expenses database migration
&lt;/p&gt;

&lt;p&gt;
At this point we have an &lt;code&gt;expenses&lt;/code&gt; database table with foreign key
references to the &lt;code&gt;events&lt;/code&gt; and &lt;code&gt;vendors&lt;/code&gt; tables. That's one side
of the coin. Rails still doesn't know exactly how to use those references in
terms of model associations.

&lt;/p&gt;

&lt;p&gt;
Specifically, we want the &lt;code&gt;Expense&lt;/code&gt; model to have a many-to-one
relationship with the &lt;code&gt;Event&lt;/code&gt; model and a many-to-one relationship with
the &lt;code&gt;Vendor&lt;/code&gt; model. And because an expense knows about both its event
and its vendor, the &lt;code&gt;Expense&lt;/code&gt; model will implicitly represent a
many-to-many relationship between events and vendors.
&lt;/p&gt;

&lt;p&gt;
Declare the associations in the models as follows:
&lt;/p&gt;

&lt;pre&gt;class Expense &amp;lt; ActiveRecord::Base
  belongs_to :event
  belongs_to :vendor
end
&lt;/pre&gt;

&lt;pre&gt;class Event &amp;lt; ActiveRecord::Base
  validates_presence_of :name
  validates_numericality_of :budget, :greater_than =&amp;gt; 0.0

  has_many :expenses
  has_many :vendors, :through =&amp;gt; :expenses
end

&lt;/pre&gt;

&lt;pre&gt;class Vendor &amp;lt; ActiveRecord::Base
  has_many :expenses
  has_many :events, :through =&amp;gt; :expenses
end
&lt;/pre&gt;

&lt;p&gt;
&lt;code&gt;Expense&lt;/code&gt; now has a many-to-one relationship with both &lt;code&gt;Event&lt;/code&gt;
and &lt;code&gt;Vendor&lt;/code&gt;. We've also created an indirect relationship between

&lt;code&gt;Event&lt;/code&gt; and &lt;code&gt;Vendor&lt;/code&gt; going &quot;through&quot; the &lt;code&gt;Expense&lt;/code&gt; join
model. The declarations read quite nicely: An expense &lt;code&gt;belongs_to&lt;/code&gt; an
event and an event &lt;code&gt;has_many&lt;/code&gt; expenses. We can declare the model
associations in a concise way and through the power of Ruby those
declarations dynamically add methods to the enclosing class for managing the
association.
&lt;/p&gt;
  

&lt;h3&gt;Accessing Models Through the Back Door&lt;/h3&gt;

&lt;p&gt;
Adding just a couple lines of code to the models has given us a bunch of new
functionality. Before we start using it in our web application, let's
experiment a bit with linking our models together. Type
&lt;/p&gt;

&lt;pre&gt; script/console
&lt;/pre&gt;

&lt;p&gt;
That command loads our Rails application into an interactive environment, then
prompts you (shown below as the &lt;code&gt;&amp;gt;&amp;gt;&lt;/code&gt; prompt) to enter Ruby code.
It shows the value of each expression (shown below after &lt;code&gt;=&amp;gt;&lt;/code&gt;)
after you press Return.

&lt;/p&gt;

&lt;p&gt;
Start by creating two new vendors in the database:
&lt;/p&gt;

&lt;pre&gt;&amp;gt;&amp;gt; vendor1 = Vendor.create(:name =&amp;gt; 'Parties R Us')
=&amp;gt; #&amp;lt;Vendor id: 1, name: &quot;Parties R Us&quot;, ...&amp;gt;

&amp;gt;&amp;gt; vendor2 = Vendor.create(:name =&amp;gt; 'Fire Department')
=&amp;gt; #&amp;lt;Vendor id: 2, name: &quot;Fire Department&quot;, ...&amp;gt;

&lt;/pre&gt;

&lt;p&gt;
Next find an event you created earlier in the web interface:
&lt;/p&gt;

&lt;pre&gt;&amp;gt;&amp;gt; event = Event.find_by_name('Chili Cookoff')
=&amp;gt; #&amp;lt;Event id: 1, name: &quot;Chili Cookoff&quot;, ...&amp;gt;
&lt;/pre&gt;
  
&lt;p&gt;
Then create two expenses that link the event to each vendor:
&lt;/p&gt;

&lt;pre&gt;&amp;gt;&amp;gt; event.expenses.create(:vendor =&amp;gt; vendor1, :amount =&amp;gt; 75.00)
=&amp;gt; #&amp;lt;Expense id: 1, event_id: 1, vendor_id: 1, ...&amp;gt;

&amp;gt;&amp;gt; event.expenses.create(:vendor =&amp;gt; vendor2, :amount =&amp;gt; 25.00)
=&amp;gt; #&amp;lt;Expense id: 2, event_id: 1, vendor_id: 2, ...&amp;gt;

&lt;/pre&gt;

&lt;p&gt;
Now you can access all expenses that directly belong to the event &lt;i&gt;and&lt;/i&gt;
all vendors that indirectly belong to the event through the expenses:
&lt;/p&gt;

&lt;pre&gt;&amp;gt;&amp;gt; event.expenses
=&amp;gt; [#&amp;lt;Expense id: 1, ...&amp;gt;, #&amp;lt;Expense id: 2, ...&amp;gt;]


&amp;gt;&amp;gt; event.vendors
=&amp;gt; [#&amp;lt;Vendor id: 1, ...&amp;gt;, #&amp;lt;Vendor id: 2, ...&amp;gt;]
&lt;/pre&gt;

&lt;p&gt;
You can also calculate the total expenses for the event:
&lt;/p&gt;

&lt;pre&gt;&amp;gt;&amp;gt; event.expenses.sum(:amount)
=&amp;gt; #&amp;lt;BigDecimal:1a04960,'0.1E3',4(8)&amp;gt;

&lt;/pre&gt;

&lt;p&gt;
Try navigating through the same associations, this time starting with a &lt;code&gt;Vendor&lt;/code&gt; object. Then use &lt;code&gt;quit&lt;/code&gt; to exit the session.
&lt;/p&gt;

&lt;h2&gt;Adding Business Logic&lt;/h2&gt;

&lt;p&gt;
Now that we can record expenses for a specific event, we can calculate the
total expenses to see if we're within budget for the event. Models not only
wrap database tables, they also encapsulate business logic such as this. So
add the following method to the &lt;code&gt;Event&lt;/code&gt; model:

&lt;/p&gt;

&lt;pre&gt;def total_expenses
  expenses.sum(:amount) || BigDecimal(&quot;0.0&quot;)
end
&lt;/pre&gt;

&lt;p&gt;
This instance method uses the &lt;code&gt;expenses&lt;/code&gt; relationship so that only those expenses belonging to a specific event are accumulated.  We used similar code previously in &lt;code&gt;script/console&lt;/code&gt;.  Bottling those details up into 
a well-named method of the &lt;code&gt;Event&lt;/code&gt; model helps keep our code clean and reusable. For example, we can also use the &lt;code&gt;total_expenses&lt;/code&gt; method to
write a new &lt;code&gt;budget_exceeded?&lt;/code&gt; method to tell us whether an event
is within budget.  Add the following method to the &lt;code&gt;Event&lt;/code&gt; model:

&lt;/p&gt;

&lt;pre&gt;def budget_exceeded?
  total_expenses &amp;gt; budget
end
&lt;/pre&gt;

&lt;h3&gt;Writing Tests&lt;/h3&gt;

&lt;p&gt;
Whenever we add business logic, trivial as it may be, we're wise to test it.
Rails makes doing the right things easy. One of those things is testing. When
we generated the event scaffolding, Rails went ahead and created a &lt;i&gt;unit
test&lt;/i&gt; for the &lt;code&gt;Event&lt;/code&gt; model and a &lt;i&gt;functional test&lt;/i&gt; for the

&lt;code&gt;EventsController&lt;/code&gt;. All we need to do is write a new unit test to cover
the business logic we added to the &lt;code&gt;Event&lt;/code&gt; model.
&lt;/p&gt;

&lt;p&gt;
Add the following test method to the &lt;code&gt;test/unit/event_test.rb&lt;/code&gt; file:
&lt;/p&gt;

&lt;pre&gt;def test_budget
  event = Event.new(:name =&amp;gt; 'Test Event', :budget =&amp;gt; 30.00)
  event.expenses.build(:amount =&amp;gt; 10.00)
  event.expenses.build(:amount =&amp;gt; 20.50)
  assert event.save
  
  assert_equal BigDecimal(&quot;30.50&quot;), event.total_expenses
  assert event.budget_exceeded?
end

&lt;/pre&gt;

&lt;p&gt;
The test uses the &lt;code&gt;build&lt;/code&gt; method to create two expenses (in memory) and
add them to the event's &lt;code&gt;expenses&lt;/code&gt; association. Then the test saves the
event (and its expenses) to the test database and asserts that the save
operation returned &lt;code&gt;true&lt;/code&gt;. With the event tucked away in the database,
the test then checks that the event's total expenses is the sum of the
expenses and that the expenses exceed the budget.
&lt;/p&gt;

&lt;p&gt;
Run all the unit tests by choosing the &quot;test:units&quot; action from the
Action toolbar item. All the tests should pass with the following output:
&lt;/p&gt;

&lt;pre&gt;....
Finished in 0.1223 seconds.

4 tests, 6 assertions, 0 failures, 0 errors
&lt;/pre&gt;

&lt;p&gt;
Remember that Rails has three default runtime environments. When you run
tests, Rails switches to the &lt;code&gt;test&lt;/code&gt; environment. Among other things,
that means the database configured in the &lt;code&gt;test&lt;/code&gt; section of the
&lt;code&gt;config/database.yml&lt;/code&gt; file will be used. In our case it's a SQLite3
database in the &lt;code&gt;db/test.sqlite3&lt;/code&gt; file. The upshot is tests can muck
with the database without affecting our development (or production) data.

&lt;/p&gt;

&lt;p&gt;
In addition to unit tests, functional tests let you easily generate simulated
HTTP requests against a controller, then assert that the controller works as
you'd expect. You can also write &lt;i&gt;integration tests&lt;/i&gt; to assert
expectations across multiple controllers. To run all the unit, functional, and
integration tests in one fell swoop, simply run &lt;code&gt;rake&lt;/code&gt;. (As it stands,
the functional tests fail because we've added validations to the
&lt;code&gt;Event&lt;/code&gt; model.)
&lt;/p&gt;

&lt;p&gt;Note: The content above being modified and rewritten again from &lt;a href=&quot;http://developer.apple.com/tools/developonrailsleopard.html&quot;&gt;Apple Developer Center&lt;/a&gt;&lt;/p&gt;
          </content>  </entry>
  <entry xml:base="http://www.usingmac.com/">
    <author>
      <name>Wendy</name>
    </author>
    <id>tag:www.usingmac.com,2008-03-11:2866</id>
    <published>2008-03-11T15:46:00Z</published>
    <updated>2008-03-11T17:01:02Z</updated>
    <category term="Productivity"/>
    <link href="http://www.usingmac.com/2008/3/11/mac-tablet-computing" rel="alternate" type="text/html"/>
    <title>Mac Tablet Computing</title>
<summary type="html">&lt;h4&gt;Axiotron ModBook&lt;/h4&gt;
&lt;p&gt;&lt;a href=&quot;http://www.axiotron.com/&quot;&gt;Axiotron Modbook&lt;/a&gt; is a tablet Mac which is retrieved by modifying MacBook. The ModBook is not designed for the masses, but that’s precisely why Apple hasn’t made a tablet Mac. Axiotron is authorized Apple solution provider. Apple is approving, even though it's not actually supporting. Maybe sooner or later, Apple will take part in the good market share for this kind of niche product solution, who knows?. You can read the &lt;a href=&quot;http://forums.axiotron.com/&quot;&gt;forum&lt;/a&gt; to find out more about this cool device.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2074/2327060062_0f6cab3fde_o.jpg&quot; /&gt;
&lt;/p&gt;</summary><content type="html">
            &lt;h4&gt;Axiotron ModBook&lt;/h4&gt;
&lt;p&gt;&lt;a href=&quot;http://www.axiotron.com/&quot;&gt;Axiotron Modbook&lt;/a&gt; is a tablet Mac which is retrieved by modifying MacBook. The ModBook is not designed for the masses, but that’s precisely why Apple hasn’t made a tablet Mac. Axiotron is authorized Apple solution provider. Apple is approving, even though it's not actually supporting. Maybe sooner or later, Apple will take part in the good market share for this kind of niche product solution, who knows?. You can read the &lt;a href=&quot;http://forums.axiotron.com/&quot;&gt;forum&lt;/a&gt; to find out more about this cool device.
&lt;/p&gt;

&lt;p&gt;
&lt;img src=&quot;http://farm3.static.flickr.com/2074/2327060062_0f6cab3fde_o.jpg&quot; /&gt;
&lt;/p&gt;
&lt;h4&gt;Mahalo Daily&lt;/h4&gt;
&lt;p&gt;Mahalo Daily came up with video introduction to this Axiotron Tablet Mac, which is also called &lt;code class=&quot;special-term&quot;&gt;Modbook&lt;/code&gt;
&lt;/p&gt;

&lt;p&gt;
&amp;lt;object height=&quot;355&quot; width=&quot;425&quot;&gt;&amp;lt;param name=&quot;movie&quot; value=&quot;http://www.youtube.com/v/mjdxyC7hr7Y&quot;&gt;&amp;lt;/param&gt;&amp;lt;param name=&quot;wmode&quot; value=&quot;transparent&quot;&gt;&amp;lt;/param&gt;&amp;lt;embed type=&quot;application/x-shockwave-flash&quot; src=&quot;http://www.youtube.com/v/mjdxyC7hr7Y&quot; height=&quot;355&quot; wmode=&quot;transparent&quot; width=&quot;425&quot;&gt;&amp;lt;/embed&gt;&amp;lt;/object&gt;
&lt;/p&gt;

&lt;h4&gt;What's Cool Inside?&lt;/h4&gt;

&lt;ul&gt;
&lt;li&gt;iSight-enabled video iChat&lt;/li&gt;
&lt;li&gt;DVD movie watching&lt;/li&gt; 
&lt;li&gt;GPS unit based on the SiRF III chipset&lt;/li&gt;
&lt;li&gt; A sensitive display fortified by Wacom's Penenabled hardware with 512 levels pressure detection.&lt;/li&gt;
&lt;li&gt;Mac OS X's Inkwell handwriting-recognition technology&lt;/li&gt;
&lt;li&gt;And &lt;a href=&quot;http://www.axiotron.com/index.php?id=mb100_techspecs&quot;&gt;more...&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h4&gt;MacWorld&lt;/h4&gt;
&lt;p&gt;
You should not miss this one. I also want to get one. I found out another video from MacWorld..
&lt;/p&gt;

&lt;p&gt;
&amp;lt;object height=&quot;355&quot; width=&quot;425&quot;&gt;&amp;lt;param name=&quot;movie&quot; value=&quot;http://www.youtube.com/v/XIPkWaR7jDw&quot;&gt;&amp;lt;/param&gt;&amp;lt;param name=&quot;wmode&quot; value=&quot;transparent&quot;&gt;&amp;lt;/param&gt;&amp;lt;embed type=&quot;application/x-shockwave-flash&quot; src=&quot;http://www.youtube.com/v/XIPkWaR7jDw&quot; height=&quot;355&quot; wmode=&quot;transparent&quot; width=&quot;425&quot;&gt;&amp;lt;/embed&gt;&amp;lt;/object&gt;
&lt;/p&gt;
          </content>  </entry>
</feed>
