Including semi-arbitrary scripting in designs?

Hi - me again.


I’d like to be able to present some online help pages using two different designs - “fancy” and “plain”. The fancy design includes a left-side navigation panel with a groovy menu structure, and a content panel to show the body content. The plain design is just the body content. The plain view is intended to be viewed in a frame (iframe, probably), so it can be selected from a search results list - which is generated by an off-site query engine (I think this is making sense). So there are essentially two ways to browse the same content tree.



Ok … I did experiment with using the SQ_ACTION and SQ_DESIGN_NAME parameters, but I ran into browser caching issues. Sometimes when the client tried to view the “default” design it would get the wrong version. It’s unpredictable.



So I’m experimenting now with two different URLs - one tree is linked to the other and given a short prefix to tell them apart. They’ll use different designs. It seems to work - I can view a page with



http://myplace/path/to/content/



And see the fancy marked-up version, or look at



http://myplace/path/to/content/



And see the plain version.



The trouble is … I need to be able to link to the fancy version from the plain version. There’ll be an automatically generated link that basically says “view the fancy version of this page” that will target the _top frame. Which means I’ll need to be able to derive the fancy version of the URL from the plain version.



Is there anything that will let me do this? It’d be a perfect application for a regex replacement.



I can feel my mind going, dave …



Thanks.

Matt.

There is no simple way to do this except by using SQ_DESIGN_NAME on the URL for the "plain" version that gets pulled into the iframe. My advice would be just to get the offsite query engine to append SQ_DESIGN_NAME=plain to the search results if possible.


One of the features on the feature request list is the ability to set designs by URL, but sadly no-one has chosen to fund this yet.

[quote]There is no simple way to do this except by using SQ_DESIGN_NAME on the URL for the "plain" version that gets pulled into the iframe. My advice would be just to get the offsite query engine to append SQ_DESIGN_NAME=plain to the search results if possible.


One of the features on the feature request list is the ability to set designs by URL, but sadly no-one has chosen to fund this yet.[/quote]



Thanks. I suspected that's where things stood.



I ran into problems with links to other pages in the help set, some automatically generated ("subtopics include") and some authored ("see also…"). I can add the SQ_DESIGN_NAME parameter to the generated links, but the authored links are a problem. For "plain" presentation they want the extra parameter, but not for "fancy" pages (Or at least a different value). I can use SQ_ACTION to tell the pages to remember the last setting, but I had problems - some relating to caching (I think) and some relating to the user jumping between the two presentations by other means (sometimes the wrong design would be used, unexpectedly). The URL approach is a lot safer.



I had to use some javascript to rewrite URLs based on a regex, but we're trying to avoid relying javascript (a decree from above), so I'm out-of-bounds.



I'll wrack my brains a bit more. Thanks. This is actually relatively minor compared with cross-browser layout/css issues. I'm thinking of joing a monastic order which has no electricity, or maybe running away to join the circus.



Matt.


Well, if you (or your company) has a spare $26k lying around, that's the cost to develop per-URL design applications. So you can have Matrix do it for you automatically. :)