tag:help-archives.hannonhill.com,2010-02-09:/discussions/general/15388-internal-link-selector-not-workingCascade CMS: Discussion 2013-10-10T19:32:16Ztag:help-archives.hannonhill.com,2010-02-09:Comment/283672762013-08-21T14:21:40Z2013-08-21T14:21:40ZInternal Link selector not working<div><p>Hi Matthew,</p>
<p>A couple of questions for you to see if we can help you narrow
this down:</p>
<ul>
<li>What does the HTML source look like for the link just after
you've added it in the Edit interface?</li>
<li>After you click Submit, click the Preview pane. Then,
right-click on the page, select 'this frame' and view the source.
What does the HTML source look like for the link here?</li>
<li>Are you applying a Block and/or Format to the region in
question? If so, can you attach the Format here?</li>
</ul>
<p>Thanks</p></div>Timtag:help-archives.hannonhill.com,2010-02-09:Comment/283672762013-08-21T18:41:50Z2013-10-10T19:31:58ZInternal Link selector not working<div><p>I have attached 2 screenshots and the frame source. The way this
particular page works is that it is a Page that inserted into
another page like a block. We call it a widget and it only seems to
cause issues when we link it to the admissions subdomain/site. This
doesn't happen with link on the same site.</p></div>matthew.wrentag:help-archives.hannonhill.com,2010-02-09:Comment/283672762013-08-26T13:49:11Z2013-08-26T13:49:11ZInternal Link selector not working<div><p>OK, it looks like you may have forgotten to attach the Format
that is transforming this content. Can you attach that here? My
guess is that it may be using the <code><path></code> element
when it should really be using the <code><link></code>
element to output the links.</p></div>Timtag:help-archives.hannonhill.com,2010-02-09:Comment/283672762013-08-26T19:40:55Z2013-10-10T19:31:58ZInternal Link selector not working<div><p>Oh my apologies. Is this the correct format? It's the format for
the widget.</p>
<pre>
<code><xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:output indent="yes" method="html"/>
<xsl:template match="system-data-structure">
<div class="call-out-links">
<ul class="menu">
<xsl:apply-templates select="call-to-action/link/link"/>
</ul>
</div>
</xsl:template>
<xsl:template match="link">
<li>
<xsl:if test="(position() = 1) and (name(parent::*) != 'subitems')">
<xsl:attribute name="class">first</xsl:attribute>
</xsl:if>
<xsl:if test="(position() = last()) and (name(parent::*) != 'subitems')">
<xsl:attribute name="class">last</xsl:attribute>
</xsl:if>
<xsl:choose>
<xsl:when test="(link-page/page/path != '/') or (link-external/url != '/' and link-external/url != 'http://') or (link-file/file/path != '/')">
<a>
<xsl:attribute name="class">
<xsl:value-of select="icon"/>
</xsl:attribute>
<xsl:choose>
<xsl:when test="link-page/page/path != '/'">
<xsl:attribute name="href">[system-asset]<xsl:value-of select="link-page/page/path"/>[/system-asset]</xsl:attribute>
</xsl:when>
<xsl:when test="link-file/file/path != '/'">
<xsl:attribute name="href">[system-asset]<xsl:value-of select="link-file/file/path"/>[/system-asset]</xsl:attribute>
<xsl:attribute name="target">_blank</xsl:attribute>
<xsl:attribute name="title">
<xsl:value-of select="link-text"/>- This link will open in a new window.</xsl:attribute>
</xsl:when>
<xsl:when test="link-external/url != '' and link-external/url != 'http://'">
<xsl:attribute name="href">
<xsl:value-of select="link-external/url"/>
</xsl:attribute>
<xsl:if test="link-external/target = 'New Window'">
<xsl:attribute name="target">_blank</xsl:attribute>
<xsl:attribute name="title">
<xsl:value-of select="link-text"/>- This link will open in a new window.</xsl:attribute>
</xsl:if>
</xsl:when>
</xsl:choose>
<strong>
<xsl:value-of select="text1"/><xsl:text> </xsl:text>
</strong>
<xsl:value-of select="text2"/>
</a>
</xsl:when>
<xsl:otherwise>
<strong>
<xsl:value-of select="text1"/><xsl:text> </xsl:text>
</strong>
<xsl:value-of select="text2"/>
</xsl:otherwise>
</xsl:choose>
<xsl:if test="../subitems/link/text1 != ''">
<ul>
<xsl:apply-templates select="../subitems/link"/>
</ul>
</xsl:if>
</li>
</xsl:template>
</xsl:stylesheet></code>
</pre></div>matthew.wrentag:help-archives.hannonhill.com,2010-02-09:Comment/283672762013-09-04T12:48:16Z2013-10-10T19:31:59ZInternal Link selector not working<div><p>Is there an update? Is there anything else I'm missing?</p></div>matthew.wrentag:help-archives.hannonhill.com,2010-02-09:Comment/283672762013-09-04T14:09:36Z2013-09-04T14:09:36ZInternal Link selector not working<div><p>Thank you for providing your XSLT Format, Matthew.</p>
<p>As Tim indicated, it looks like you are using asset path as
opposed to using the link. The main difference between the two is
you need to use link if you are referencing assets that are in
another Site, or using the Format within another Site. This will
have the <code>site://</code> prefix that will tell Cascade Server
the asset you are linking to is within a specific Site and not the
same Site.</p>
<p>Specifically, you will want to update lines similar to the
following:</p>
<pre>
<code><xsl:attribute name="href">[system-asset]<xsl:value-of select="link-page/page/path"/>[/system-asset]</xsl:attribute></code>
</pre>
<p>To:</p>
<pre>
<code><xsl:attribute name="href">[system-asset]<xsl:value-of select="link-page/page/link"/>[/system-asset]</xsl:attribute></code>
</pre>
<p>Note: you would still want to use the path value when checking
if a chooser has a chosen asset (ie looking to see if the value is
<code>/</code>).</p>
<p>Please let me know if you have any questions.</p>
<p>Thanks!</p></div>Ryan Griffithtag:help-archives.hannonhill.com,2010-02-09:Comment/283672762013-09-09T17:27:38Z2013-10-10T19:32:16ZInternal Link selector not working<div><p>That seems to be the problem! Thank you very much!</p></div>matthew.wrentag:help-archives.hannonhill.com,2010-02-09:Comment/283672762013-09-11T19:51:17Z2013-09-11T19:51:17ZInternal Link selector not working<div><p>Glad we could help! Take care, Matthew.</p></div>Tim