Migrating to CityDesk

by Darren Collins
Thursday, 13 June 2002

CityDesk is great, but moving an existing site into it can be difficult at first. Here are a few tips that I've found helpful.

Preserving URLs (Preventing Link Rot)

When you import an existing site into CityDesk, you'll probably take the opportunity to rethink your layout and site design, and maybe move things around a bit. This can result in URLs for some of your existing pages changing.

If you've spent months (or years) getting your pages near the top of various search engines, and have an array of sites linking to yours, the last thing you want to do is to suddenly change the URLs of all your pages. Nobody will be able to follow old links to your site or return to pages they have bookmarked, and you'll miss out on all those eyeballs that were rightfully yours.

To get around this problem, you can set up a dummy page that will redirect the visitor from the old URL to the new one.

  • First, set up a folder in CityDesk that matches the path to the web page on your old site. For example, if the old URL was 'www.yourdomain.com/foo/bar/baz.html', you'd need to create a folder named 'foo' in the CityDesk main window. Inside that folder, create a subfolder named 'bar'.
  • Then create a file named 'baz.html' in the new folder. Open up the file, and in the HTML View paste in the following:
<html>
<head>
<meta http-equiv="Refresh" content="0;url=PTMFOGXXX">
<title></title>
</head>
<body>
<A href="PTMFOGXXX">Document Moved</A>
</body>
</html>
  • Replace the two occurrences of PTMFOGXXX in the code above with the Magic Name of the article you want to send the user to. You can get the Magic Name by right-clicking on the article in the CityDesk main window, and selecting Copy Magic Name. Then highlight PTMFOGXXX, right-click, and select paste.

Now, whenever someone tries to access the old URL, they'll be redirected to the new one.

A side benefit of this technique is that you can check your server logs to see who is referring people to the old URLs, and ask them to update their links.

New And Improved Redirect Method

Thanks to MarkTAW, who suggested an even better way to achieve the same thing as above:

  • First, set up a template named "Redirect". In the body of the template, put this code:
<html>
<head>
<meta http-equiv="Refresh" content="0;url={$.body$}">
<title></title>
</head>
<body>
<A href="{$.body$}">Document Moved</A>
</body>
</html>
  • Save and close the template.

Now, each time you want to create a redirect file:

  • Create a folder to hold your redirect file, just like the old method. So if the old URL was 'www.yourdomain.com/foo/bar/baz.html', create a folder named 'foo', with a subfolder named 'bar'.
  • In the foo/bar folder, create an article named 'baz (redirect)'. CityDesk will publish this article with the name 'baz.html' (anything in brackets in the article name doesn't become part of its filename).
  • Right-click on the real article in the Main Window (the article you want to send people to), and select Copy Magic Name. Now open your new redirect article, right-click in the body, and select Paste. Click on the Properties tab, and change the Template field to 'Redirect'.
  • Save and close the article. That's it — none of that messy copying and pasting of HTML code!

 


Related Articles
Index
- Handy Variables
- Design Test Page
- CityDesk Beta 2.0.1 First Impressions
- Boxed Content
- Managing Content Fragments
- CityDesk Short Tips
- Template Mockups
- Creating A Main Page
- Index Pages
- Using Folders
- Committee Intranet Site
- Migrating to CityDesk
- CityDesk First Impressions
- CityDesk Links

This site Copyright 1999-2005 Darren Collins.