Fog Creek Software
Discussion Board




Knowledge Base
Documentation
Terry's Tips
Darren's Tips

Creating links to CD pages in Word

I simply have to write in MS Word because of the feable CityDesk editor; I then simply copy/paste pages to CityDesk.

I need to create links to other CityDesk pages, so I tried copying the Magic Name into Word's hyperlink dialog box. This cretes a link to the correct fogxxx.html file, but unfortunately with the wrong path: the path were the Word file resides.

Any idea on a better way for creating links to CityDesk pages while writing in Word?

Paul Iliano
Thursday, February 21, 2002

I never figured this out to my satisfaction so I usually create the links after I copy the text into CityDesk.  I'm sure someone has a better idea though.

TK
Thursday, February 21, 2002

Yes, creating the link in CityDesk after pasting is what I have to do now too.
But that's not a workable long term solution: each and every time the Word text is updated and thus copy/pasted, you have to track where the links are and recreate them!

Paul Iliano
Friday, February 22, 2002

I just tried this and I think made it work.  I created a Word file, saved it, and dragged it into my CityDesk site.  Then, edited the Word file by using "Open with."  I used magic names to create links in the Word document.  Does that work for you?

TK
Friday, February 22, 2002

Thanks TK! When I copy these texts with links created in Word, the links work fine; I checked after publishing via FTP to a server too.

As far as I can judge, this Word file will be published with the rest of the site each time? Since it's not an article, there's no way to somehow (via audiences or dates) set the Word file not to be published each time.
The problem in my specific case is my Word file is 3 MB (it's 4 years work of research or roughly 500 pages on the subject of quality of life, which I'm now transferrig bit by bit to a CD site to share it with the world).
Is there a way not to publish the Word file each time?

Paul Iliano
Friday, February 22, 2002

Owww!  Didn't think of that:  Give with the right while taking away with the left.

There has been a lot of forum talk about methods to turn off publishing for articles, but not for files.  Maybe there is a trick we don't know about yet.

TK
Friday, February 22, 2002

The word file should only be published the first time - uploaded to the server that is. For each subsequent time, CityDesk should check a "citydesk.xml" in the root directory of your site and only upload the files that have changed.

If the issue is uploading a 4mb file every time, well, this should only happen when that file changes. If the issue is that this file is out there at all and it never changes, perhaps then publishing it once, and deleting it from the server should do the trick. CityDesk will think it's still there because of the citydesk.xml file and never publish it again.

Perhaps this is a good time to revisit my "files as articles" thread. My only real wish for Sp1. Since in the database, the body is some sort of LOB (did I hear someone say BLOB?), it should be easy to just swap the body out for some file. This way you could control publishing via the normal Article ways.

The only non-obvious thing I would like to ensure is that you could easily swap the actual file, just like editing the body, so that an update (to version 1.1 of a document, for example) doesn't mean you have to re-enter the author, teaser, keyword information, etc.

Also, does the file create an Article with a link do the file, or does the [[teaser]] link straight to the file? What about {$x.link$}? My favorite option is to create a new field {$x.file$} so you can create an article around a file, or link to it directly. My mental model is the IBM.com document repository and download.com and similar sites, though I doubt we could get anyone to write even a sentance about every document on our site.

From what I've heard from the FogCreek folks on this board, this is the way they're going (i.e. HTML & Article are similar, make Article filename anything you want, etc.) and I'm actually waiting on this before I convert our document repository into CityDesk. This would then allow us to automate 3 or 4 normally unrelated sites (except that they all have documents on them) in one fell swoop, AND allow us to create different views of the information, I.e. "show me all forms" "show me all brochures" "show me all documents for US based products" etc.

For now though, all I can do is wait and hope.

Mark W
Friday, February 22, 2002

Mark is correct about the publishing - should only be done once (unless the file changes).

There are two steps to publishing: first, to write the files out to disk with all the cityscript parsed, and second to ftp or copy the files to the server.  When you quit citydesk it deletes the temp directory it uses for the first part so you may see the word file being written out to disk (which should be somewhat fast) each time you restart, but it won't republish the file to the server (which can be slow).

There is a bug which will be fixed in SP1 where when you do a "Save and Publish" for a particular file, it will do a full publish the next time you publish.  This will be fixed.

Michael H. Pryor
Friday, February 22, 2002

In fact, this large Word file will constantly change as it is constantly being edited as the source document where all findings are recorded and 'articles' written. So it will be published each time :-(

In fact, I support Mark's quest for his 'files as articles' feature. It would allow me to split up the large Word file into small files, 1 for each CD article, where the Word file would simply replace the article body, with the article supplying the metadata (title, keywords, etc). Only those (small) Word files that have changed would be published.

But ... MUCH more importantly, it would make my current copy/paste chore superfluous: BY USING WORD FILES AS THE BODY FOR ARTICLES, WE WOULD HAVE THE POSSIBILITY TO USE WORD AS OUR CITYDESK EDITOR, PRESTO!!!

I'm salivating at the thought of being able to write in Word instead of the meager CD editor - it would make CD so much more useful for my kind of work - perhaps for others too?

Paul Iliano
Friday, February 22, 2002

I just tested this in Word 97. I created a document, copied the magic name to an article as a link, turning *on* the "Use relative path for hyperlink" checkbox. Then I copied and pasted it into CityDesk.

Here's the HTML CityDesk gave me:

<FONT size=2>
<P></FONT><A href="PTMFOG0000000047"><FONT size=2>Asdfasdfasdfasdf</FONT></A><FONT size=2> </P></FONT>

Are the relative links turned off in your version of Word? Then it will create an absolute link to the file as follows:

<FONT size=2>
<P></FONT><A href="file:///C:/WINNT/Profiles/mwieczor/Desktop/PTMFOG0000000047"><FONT size=2>Asdfasdfasdfasdf</FONT></A><FONT size=2> </P></FONT>

If you have the option to turn ON "Use relative path for hyperlink" do so. The actual link to the file shows at the bottom of the link dialogue screen in Word. This then seems to be Word "bug", not a CityDesk bug.

Mark W
Friday, February 22, 2002

* sorry, no at the bottom, in the "path" box, at least in my versin of Word.

Mark W
Friday, February 22, 2002

Thanks Mark!

I'm using Word 2002, and the Edit Hyperlink dialog must be quite different from Word 97. There is no check box for relative links. But the Help told me there is now a field in File > Properties > Summary tab, called "Hyperlink Base". The Help says "Hyperlink base: When a relative link is based on a path you specify (the first part of the path that is shared by the file containing the hyperlink and the destination file), that path is the hyperlink base."

After putting "../" in this Hyperlink Base field, copy/pasted text containing links with Magic Names work fine.

Paul Iliano
Saturday, February 23, 2002

*  Recent Topics

*  Fog Creek Home