tag:help-archives.hannonhill.com,2010-02-09:/discussions/how-do-i/342-force-link-from-one-configuration-to-anotherCascade CMS: Discussion 2018-10-18T20:36:11Ztag:help-archives.hannonhill.com,2010-02-09:Comment/53854082011-02-16T16:09:26Z2011-02-16T16:09:26ZForce Link from one Configuration to Another<div><p>We have set up a content sharing method for a client so they
could have one page (I'll name this Page A) feed its WYSIWYG
content to several other pages. They do this by using an Asset
Factory called "Shared Content". This page, which I'll name Page B,
simply has a page selector on it, where they select which page's
content to show.</p>
<p>The enhancement we did is that, in addition to publishing as a
regular Web page, Page A also publishes out its WYSIWYG content as
a .NET include file. This include file is then called into Page B.
The purpose of this is to eliminate the need to publish all Page Bs
when Page A's content changes.</p>
<p>This all works fine, except the problem is that since Page B is
calling in Page A's content via this include, all links within the
content want to link to other page's "Include" configuration set,
not the default Configuration set. So all links have
"-include.aspx" tacked onto the end of them, and we don't want
that.</p>
<p>We've tried .NET solutions to avoid this, but for various
reasons, they don't work. So my question is, is it possible tell
all links in a configuration to always go to the "HTML"
configuration of whatever page it's linked to? For obvious reasons,
we can't expect the content contributors to know how to tell each
link, "Go to the HTML configuration for this page". Thanks!</p></div>jklingmantag:help-archives.hannonhill.com,2010-02-09:Comment/53854082011-02-16T18:46:26Z2011-02-16T18:46:26ZForce Link from one Configuration to Another<div><p>You could attach a page-wide XSL to this configuration that can
parse all the anchor tags in the document and string-replace out
the -include part of each HREF attribute.</p>
<p>We wrote an XSL to rewrite all links in a page for a different
reason. I'll attach it here.</p>
<p>Yours should be much, much simpler than this obviously. Ours
rewrites CSS references, JS references, and image paths so we can
publish templates that can be ingested into other content
management systems (e.g. Wordpress). With some XSL hacking (or you
could start fresh) this should be doable.</p></div>Lee Roberson (Function Digital LLC)tag:help-archives.hannonhill.com,2010-02-09:Comment/53854082011-02-18T15:41:52Z2011-02-18T15:41:52ZForce Link from one Configuration to Another<div><p>Thanks Lee! I'll have my developer give this a shot.</p></div>jklingmantag:help-archives.hannonhill.com,2010-02-09:Comment/53854082011-03-03T05:22:55Z2011-03-03T05:22:55ZForce Link from one Configuration to Another<div><p>This worked perfectly, with some tweaking. Thank you again,
Lee!</p></div>jklingman