Is iCloud deleting your iCal events? Here’s a possible solution

Like many Apple enthusiasts, I spent much of the day yesterday updating software. Mac OS X 10.7.2, iTunes 10.5, iOS 5, and… iCloud. I’ve been relying on MobileMe for a little over a year to keep my mail, notes and calendars (mostly) in sync. I was not an “early adopter” with MobileMe, so I escaped the first-day glitches that promted Steve Jobs to declare the system’s launch “not our finest hour.”

Less than a day into my experience with iCloud, I’d have to say that this launch also is not Apple’s “finest hour.” There have been numerous complaints today about iCloud mail outages (following what I have observed as several days of flaky MobileMe mail performance). But without a doubt the biggest issue for me personally has been related to iCal.

After completing the iCloud transition yesterday, to my dismay I discovered that all of my iCal events were duplicated! My MobileMe account and my iCloud account were both showing up, with all of the same events. Now, in retrospect, the correct thing to do would probably have been to go to Preferences > Accounts and just delete the MobileMe account from my iCal configuration. But is that what I did? Why, no, of course not! I proceeded to delete all of my individual MobileMe calendars. That appeared to do the trick. The iCloud calendars were still there, and every event was just showing up once.

But then this morning I sat down at my computer and discovered — to my horror — that everything was gone. At some point yesterday, when I wasn’t looking, MobileMe and iCloud synced up, and deleted all of my events.

Time Machine to the rescue!

I opened up my Time Machine backup from yesterday afternoon… sometime just before I had made the iCloud transition. I drilled down to [home]/Library/Calendars. (Note that Library is now a hidden folder, but I have my system set to show hidden files and folders*.) I found the multitude of .ics files that represent each individual calendar event, and dragged them into iCal. At first, things seemed great… until I noticed that one by one, the events started disappearing from my calendar again! Apparently iCloud didn’t like having these events show up in the calendar in this way — probably because it recognized them as being events I had “deleted” yesterday — so it “helpfully” removed them again.

AAAAARGH!!! How am I supposed to get these events back into iCal when iCloud just deletes them as soon as they’re added?! Then it hit me… you don’t have to put events into iCloud calendars.

iCal also allows you to created local calendars (“On My Mac”). My solution was to — temporarily — create new “On My Mac” calendars, add the events to those calendars, then export those calendars and import them back into the iCloud calendars. (Then the “On My Mac” calendars can be deleted.) It worked!

Here are step-by-step instructions to do what I did, in case you’ve found yourself in the same conundrum.

1. Find the old calendars in your Time Machine backup. You could open Time Machine to do this, but I like to just explore the disk in the Finder. (The remaining instructions assume you’re taking my approach.) The most important thing is to determine the date and time when your last “good” iCal backup would be. Drill down into that backup to your home directory (that would be something like [drive name]/Users/[username]), and then to Library/Calendars. (Remember that Library may be hidden; if so, see the footnote below.) You’ll see one or more weirdly-named folders. Each of these represents a separate calendar in iCal. Inside each is a directory called Events, and inside that are all of the events on that calendar, each with a filename ending in .ics. If you have more than one calendar folder, you can tell which calendar this is by selecting one of the events in the Finder; its icon will show its date and title. Keep this folder open; you’ll need to come back to it in a later step.

2. Create a new “On My Mac” calendar in iCal. Go to File > New Calendar > On My Mac. Call this calendar whatever you want. If you have multiple calendars, like I do, you’ll need to repeat this process for each of them separately (to keep your events from all getting jumbled together in one calendar).

3. Set the new “On My Mac” calendar as the default calendar. This can be found under iCal > Preferences > General > Default Calendar. When you drag events into iCal, it automatically assigns them all to the default calendar, so this is a pretty important step. Reassigning the events to a new calendar once they’ve already been imported can be a pain.

4. Drag all of the backed-up events into iCal. Go back to the Time Machine backup window you left open in step 1, select all of the .ics files, and drag them into the iCal window. Depending on how many there are, it may take a while for them all to load. Once they’re in, proceed to the next step.

5. Export the “On My Mac” calendar. It can be tricky to make sure you’re getting iCal to export the correct events. Click the Calendars button in the upper left of the iCal window (on the brown “binding” of the cutely skeuomorphic interface), find the “On My Mac” calendar that you’ve added all of the events to, and right-click (Control-click) that calendar to get a contextual menu. Click Export... and follow the prompts. I recommend saving the exported file to your desktop.

6. Set the appropriate iCloud calendar as the default calendar. This is a repeat of step 3, but this time you’re changing it to the iCloud calendar you want the events to be loaded into.

7. Import the exported calendar file into the iCloud calendar. Go to File > Import > Import... and locate the file you created in step 5.

8. Delete the “On My Mac” calendar. Once you’ve completed the import (and have confirmed that the events are not disappearing), you can safely delete the “On My Mac” calendar you created. Click the Calendars button in the brown “binding” again, right-click (Control-click) the “On My Mac” calendar, and select Delete from the contextual menu.

9. There’s no step 9!

* To get your system to show hidden files and folders, open up Terminal and type this: defaults write com.apple.Finder AppleShowAllFiles TRUE then hit Return, type this: killall Finder and hit Return again.

Search Engine Optimization (SEO): the good, the bad and the (mostly) ugly

Years ago I first encountered a mysterious acronym: SEO. I bristled when I learned what it meant: Search Engine Optimization. The term can be both innocuous and poisonous. In its innocuous form, it means, quite simply, presenting your site in a way that is most likely to lead to prominent placement in search results. In its poisonous form, it means deceiving the algorithms search engines use, in essence, tricking the search engines into listing your site when they shouldn’t.

That the latter connotation has become the primary meaning of the term is unfortunate, as there is a legitimate role in web design and development for tuning your website for maximum effectiveness in search engine listings. Doing it the right way does not involve gaming the system. In fact, the principles of sound search engine optimization aren’t really about search engines at all: they’re simply rules of good design, ensuring that your site is well-formed, well-organized and intuitive. In short, the best honest ways of appealing to a search engine’s algorithms are going to be the same ways of appealing to the real target of your website: human users. After all, the goal of a search engine like Google is to deliver the most relevant results to its users. And if your site isn’t relevant to a particular user, it shouldn’t be coming up in their search results anyway.

Derek Powazek has an excellent blog entry called Spammers, Evildoers and Opportunists that pulls no punches in criticizing the dark side of SEO. So much so, in fact, that one questions whether there is any other side to it. Ultimately, maybe not. The question then is what to call the best practices in web design and development that just happen to also be the most effective legitimate ways to optimize your site for search engine placement. I don’t have an answer, but I have to admit that after reading his blog, I’m reluctant to use the term “Search Engine Optimization” any longer.

Some background here: for the past year or so I’ve been including a brief section in all proposals I’ve created for new clients, entitled “Search Engine Optimization,” wherein I talk about these best practices, criticize unscrupulous SEO tactics, and give my recommendations for how best to build a website (in ways that also just happen to be good for search engine placement). I give this information away for free. I do, however, charge my clients for work I do to these ends. It’s not smoke and mirrors, and it’s not snake oil. But it is actual work, it does take time, and if it’s not something the client can or will do for themselves, then it’s something I need to bill them for. Powazek says:

Look under the hood of any SEO plan and you’ll find advice like this: make sure to use keywords in the headline, use proper formatting, provide summaries of the content, include links to relevant information. All of this is a good idea, and none of it is a secret. It’s so obvious, anyone who pays for it is a fool.

Right on, brother. But here’s the thing: while I will gladly share this information with any client for free, there is still work involved to implement these ideas. And if I’m the one doing the work, I bill for it, just like any other work I do. I believe what he’s really criticizing is the practice of charging simply for sharing this information. Much like the late-night infomercials that promise riches in real estate, the real get-rich-quick scheme is in selling the information itself; the person who’s going to get rich is the one selling training books and videos, not land.

Let the information be free. Here, word for word, is the information I include in every proposal I write:

Search Engine Optimization

“Search Engine Optimization” (SEO) is a common buzzword today, but what does it really mean? Many web consultants will offer “advanced SEO techniques” and submission to thousands of search engines. But most of these techniques are dubious at best, and most of the thousands of search engines are irrelevant to directing significant traffic to a website.

Ultimately there are a few simple principles that, when implemented on a website, will help to ensure the site receives proper placement in the search results of the most popular search engines, like Google, Yahoo! and MSN. Because the principles are so basic, and correspond so closely with the principles of simple, clean, well-organized web design in general, Room 34 offers these recommendations, free of charge, as a standard part of all website proposals:

Title Bar

The web browser’s title bar is easy to ignore, but a well-structured page title is one of the most important ways to ensure that your site is listed prominently in search engine results. The title should be clear, relevant, detailed, and specific. Each page of the site should have a title that accurately reflects what is on the page. The page title should begin with this specific information, followed by general information that is the same for every page: your business name, the nature of your business, and if relevant, your city and state.

Meta Tags

Meta tags do not appear anywhere on the web page, but they are included in the HTML header of the page to assist search engines in identifying the relevance of a web page if its textual content does not fully reflect its purpose. There are two primary meta tags used by search engines: keywords and description. Keywords is a comma-separated list of words or phrases that describe the content of your page. The description is a sentence or two that can be used in search engine results to summarize the content of your page. Meta tags should be as concise and accurate as possible. Excessive repetition of terms, or content that does not accurately reflect what is on the page will hurt search engine rankings rather than help them.

Semantic HTML

Semantic HTML means HTML that is built to reflect the logical structure of a web page document, with visual presentation separated into CSS (Cascading Style Sheets) rather than embedded within the HTML. Fonts, colors and visual layout elements should be restricted to the CSS. HTML tables should be used for tabular information only, not layout and positioning. The content of the page within the HTML should be organized such that the page is logical and readable with CSS turned off. Also, it is increasingly important that documents be formated with valid XHTML rather than older HTML specifications. Pages should be checked against an XHTML validator (http://validator.w3.org) to ensure accuracy.

Accessibility

Building web pages with proper accessibility for visually-impaired visitors also helps to ensure a semantic HTML structure that will improve search engine rankings. All images and other visual content should include “alt” text. Content that requires Flash, JavaScript or other browser plug-ins should also include a standard fallback version to allow them to “degrade gracefully” for screen readers, browsers without these add-on features, mobile devices, and search engines. By organizing features like site navigation into standard HTML unordered lists instead of elaborate table layouts or Flash elements, pages will be both more widely accessible and more relevant in search engine results.

Relevant Links

Most modern search engines like Google use cross-site links as an indication of a site’s popularity and relevance in a particular field. By exchanging meaningful links with relevant sites in a particular field, a site can improve its search engine results. There may be a temptation here to exchange links with sites that are simply aggregators of links. This might provide a temporary boost to search engine placement, but ultimately if the links are not on sites that offer real live users a meaningful web experience, they will not provide long-term benefit. Before exchanging links with another site, consider whether or not it is a site you would visit and trust as a resource. If not, it is probably not worth the effort.

No Magic Bullet

There is no secret weapon to ensure top search engine placement. Many promises of search engine optimization rely on short-term “gaming” of a search engine’s relevance ranking algorithms. But just as the “gamers” evolve their tactics, the search engines are constantly being enhanced to counteract them. Ultimately the best way to ensure long-term relevance within search engine listings is to stick to the principles of well-organized, validated XHTML documents and meaningful content.

Introducing the Room 34 Music Player

OK, I didn’t create the music player myself. It’s the freely available, Flash-based XSPF Player. But it’s a pretty slick tool to create a custom music playlist on your own website.

So now I have a convenient link you can click on to open up my music player in its own little pop-up window. It’s preloaded with all 23 tracks from the five LP/EP releases I’ve put out this year. (Yes, five! I’ve been quite prolific. I’ll leave it to you to weigh the “quantity vs. quality” issue.) And, for future reference, there’s a link to it right under the “Room 34 CDs and MP3s” heading in the sidebar on every page.

Enjoy!