duplicate content publishing

123 views
Skip to first unread message

gk

unread,
Jan 23, 2011, 8:03:19 PM1/23/11
to RedDot CMS Users
Having problems with duplicate content publishing. I've followed the
directions in http://www.reddotcmsblog.com/duplicate-content-publishing-seo-and-open-text-web-solutions
but the only way I can get the link to reference (isLink=10) rather
than connect (isLink=2) is to put the asp replace code directly in the
link. This bit works perfectly now (the link is pointing to the
correct place) but the linked page is still being published in two
places with the second one ending up as an orphan since nothing is
linking to it.

I'm on Version 9 and the linking is being done with keywords. If it's
any help, the content class looks like this:

<div id="feature">
<h2>Featured</h2>
<!IoRangePreExecute>
<!IoRangeList>
<h3><a href="<%=Replace("<%list_pages%>","islink=2","islink=10")
%>"><%text_feature_title%></a></h3>
<p><%img_feature%><%text_feature_summary%></p>
<div class="button-grey">
<div class="button-grey-text">
<a href="<%=Replace("<%list_pages%>","islink=2","islink=10")
%>">More about <%text_feature_short%></a>
</div>
</div>
<!/IoRangeList>
<!/IoRangePreExecute>
</div>

kimdezen

unread,
Jan 23, 2011, 9:29:25 PM1/23/11
to RedDot CMS Users
the CMS will still publish the additional page as the list placeholder
is exposed in the HTML source. The replace method will just change the
location of the displayed link in the page - not if and where the
linked pages are published to.

The only way to stop pages from publishing is to 'hide' the list
placeholder. As shown in the article, to do this you need to wrap the
list placeholder within NoRedDot and RedDot mode block marks - so
essentially the link is hidden from the source and the links wont be
published. Its important the the list placeholder is displayed within
the list block marks so each page connected to the list will still get
processed:

<!IoRangeNoRedDotMode><!IoRangeRedDotMode><!--
'treat the link as reference not as link to avoid
duplicate publishing
<%=Replace("<%list_teaser%>","islink=2","islink=10")%>
--><!/IoRangeRedDotMode><!/IoRangeNoRedDotMode>


To display the correct link to the page, use the following:

<a href="<%!! Context:Pages.GetPage(Guid:<%info_PageGuid%>).GetUrl() !!
%>"><%hdl_pagetitle%></a> - the <%info_PageGuid%> is the page guid
pulled in from the connected page. You will need to ensure that this
placeholder is within the connected page template for this method to
work.


Hope that helps!

Kim




<div id="feature">
<h2>Featured</h2>
<!IoRangePreExecute>
<!IoRangeList>
<h3><a href="<%=Replace("<%list_pages%>","islink=2","islink=10")
%>"><%text_feature_title%></a></h3>
<p><%img_feature%><%text_feature_summary%></p>
<div class="button-grey">
<div class="button-grey-text">
<a href="<%=Replace("<%list_pages%>","islink=2","islink=10")
%>">More about <%text_feature_short%></a>
</div>
</div>
<!/IoRangeList>
<!/IoRangePreExecute>
</div>




On Jan 24, 12:03 pm, gk <gail.b...@tga.gov.au> wrote:
> Having problems with duplicate content publishing. I've followed the
> directions inhttp://www.reddotcmsblog.com/duplicate-content-publishing-seo-and-ope...

gk

unread,
Jan 23, 2011, 11:16:32 PM1/23/11
to RedDot CMS Users
Thank you. I didn't realise that the info_PageGuid placeholder didn't
exist on the referenced page but I've corrected that.

I've changed all the rest of the code as advised but the referenced
page is still publishing to two places.

My code now looks like:

<div id="feature">
<h2>Featured</h2>
<!IoRangeList>
<!IoRangePreExecute>
<h3><a href="<%!! Context:Pages.GetPage(Guid:<%inf_PageGuid
%>).GetUrl() !!%>"><%text_feature_title%></a></h3>
<p><%img_feature%><%text_feature_summary%></p>
<div class="button-grey">
<div class="button-grey-text">
<a href="<%!! Context:Pages.GetPage(Guid:<%inf_PageGuid
%>).GetUrl() !!%>">More about <%text_feature_short%></a>
</div>
</div>
<!IoRangeNoRedDotMode><!IoRangeRedDotMode><!--
'treat the link as reference not as link to avoid
duplicate publishing
<%=Replace("<%list_pages%>","islink=2","islink=10")%>
--><!/IoRangeRedDotMode><!/IoRangeNoRedDotMode>
<!/IoRangePreExecute>
<!/IoRangeList>
</div>

Jian Huang

unread,
Jan 24, 2011, 1:35:53 PM1/24/11
to RedDot CMS Users
Hi gk,

If you are on 10.1, from discussion here
http://groups.google.com/group/reddot-cms-users/browse_thread/thread/2abea5c5c6e5a3fa
from stefan.popp, you may try

GetUrl(Bool:True)

instead of

GetUrl()

So the final code should be (also, preexecution isn't neccessary in
this case):

<div id="feature">
<h2>Featured</h2>
<!IoRangeList>
<h3><a href="<%!! Context:Pages.GetPage(Guid:<%inf_PageGuid
%>).GetUrl(Bool:True) !!%>"><%text_feature_title%></a></h3>
<p><%img_feature%><%text_feature_summary%></p>
<div class="button-grey">
<div class="button-grey-text">
<a href="<%!! Context:Pages.GetPage(Guid:<%inf_PageGuid
%>).GetUrl(Bool:True) !!%>">More about <%text_feature_short%></a>
</div>
</div>
<!IoRangeNoRedDotMode>
<!IoRangeRedDotMode>
<!--
<%list_pages%>
--><!/IoRangeRedDotMode>
<!/IoRangeNoRedDotMode>
<!/IoRangeList>
</div>

Another out of box solution will be as a reply

Jian Huang

unread,
Jan 24, 2011, 1:45:14 PM1/24/11
to RedDot CMS Users
Continuing from previous thread.

Out of box functionality without preexecution and rendertag.
Generally referred to as the "Shadow List" trick

Have 2 lists in your template, say "list_pages" and "list_ref_pages".

Pages are connected to "list_pages" right? Good, don't change that.

Reference "list_ref_pages" to "list_pages"

In your template code, loop "list_ref_pages" instead of "list_pages".
This tricks page builder into thinking those pages are referenced
instead of connected.

<div id="feature">
<h2>Featured</h2>
<!IoRangeList>
<h3><a href="<%list_ref_pages%>"><%text_feature_title%></a></h3>
<p><%img_feature%><%text_feature_summary%></p>
<div class="button-grey">
<div class="button-grey-text">
<a href="<%list_ref_pages%>">More about <%text_feature_short
%></a>
</div>
</div>
<!/IoRangeList>

<!IoRangeNoRedDotMode>
<!IoRangeRedDotMode>
<!--
<%list_pages%>
--><!/IoRangeRedDotMode>
<!/IoRangeNoRedDotMode>
</div>

You are still getting the page published twice? Ok, explaination in
following post.

On Jan 24, 1:35 pm, Jian Huang <jhuangsoftw...@gmail.com> wrote:
> Hi gk,
>
> If you are on 10.1, from discussion herehttp://groups.google.com/group/reddot-cms-users/browse_thread/thread/...
Message has been deleted

Jian Huang

unread,
Jan 24, 2011, 2:02:59 PM1/24/11
to RedDot CMS Users
Page published twice? Impossible, well, if you publish from parent
page that is. Unless....

Despite implementing the "Shadow List" technique, if you select a page
connected to "list_pages" and publish, the page still gets published
twice because:

Page builder tries to publish all page connections, if you happen to
have the page connected in multiple locations with multiple
publication packages, then yeah, multiple published location of the
page.

What do you asked?

Luckily, with the aforementioned technique, though the page is
published to 2 locations, all links still point to the mainlink
location that the page is published from, so the page published from
non-mainlink simply just sits on the server serving no purpose.

"That is horrible for server space usage and maybe SEO!", you said.

Create a publication target/package combo that publishes to local file
system or a folder on web server that will get deleted. Apply the
publication package to list_page.

Problem solved

gk

unread,
Jan 24, 2011, 5:05:11 PM1/24/11
to RedDot CMS Users
Thank you. The shadow list works perfectly and the page is now only
being published once in the correct place.

kimdezen

unread,
Jan 25, 2011, 1:43:03 AM1/25/11
to RedDot CMS Users
on a side note, you can set up automatic referencing within the
template - so that any new page instances will have the reference in
place if you decide to use the shadow list method!

Gavin Cope

unread,
Feb 1, 2012, 9:26:29 PM2/1/12
to reddot-c...@googlegroups.com
I know this is an old post but I've just come up against this and whilst all the above tactics work as described, it's a whole new ball game when you throw Verity or Common Search into the mix. The orphan duplicates still get indexed and thus returned in any search results.

I got around this by adding the following code to my foundation templates:
<reddot:cms>
  <if>
    <query valuea="String:<%inf_UrlOfCallingPage%>" operator="==" valueb="String:<%inf_UrlOfCallingPageMainLink%>">
      <htmltext>
        <rde-dm:import>
          <keywords mode="set" keyword-separator="," name-value-separator=":" hierachy-separator=".">
            IsMainLink:1
          </keywords>
        </rde-dm:import>
      </htmltext>
    </query>
    <query type="else">
      <htmltext>
        <meta name="robots" content="noindex" />
      </htmltext>
    </query>
  </if>
</reddot:cms>

I then added (IsMainLink:1) to my search queries and - as if by magic - all the duplicates disappeared :)

To explain the above code, it compares the URL of the Calling Page and the URL of the Calling Page's Main Link. If they're the same thing, the page is tagged. If the two values don't match, no tag is added and for good measure, I put in a meta tag to prevent any external search engines finding and indexing the orphan page.

So whilst this doesn't address the server space issue, the above and aforementioned tactics prevent the page being linked to or found in search results.

Cheers,

Gavin

--
You received this message because you are subscribed to the Google Groups "RedDot CMS Users" group.
To post to this group, send email to reddot-c...@googlegroups.com.
To unsubscribe from this group, send email to reddot-cms-use...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/reddot-cms-users?hl=en.


Jian Huang

unread,
Feb 2, 2012, 9:30:03 AM2/2/12
to RedDot CMS Users
A solution to make the page publish as mainlink, hence solving the
duplicate page issue can be found here

http://simplyreddot.blogspot.com/2012/01/duplicate-pages.html

-Jian

Gavin Cope

unread,
Feb 2, 2012, 6:07:46 PM2/2/12
to reddot-c...@googlegroups.com
Thanks Jian, that solution still does publish a duplicate page though even though it's not linked anywhere.

What I should have added to my post was that my code snippet above is also only run in Publish mode, thus avoiding the ampersand killing render tags issue. The tag is only required on the published page in order to allow filtering by the search engine.

Of course, this solution is only required if you're using a search engine that you need to filter out the duplicate files. Although, you still could use the cut down version to prevent Google indexing the child pages in a static site.

Cheers,

Gavin

Neil Mann

unread,
May 30, 2013, 3:32:22 PM5/30/13
to reddot-c...@googlegroups.com
I know I'm a little late to the party, but I'm having issues trying to get this to work. We are on CMS 7.5 and I cannot get the render tag to work for the life of me. What would be the best way to display the url in 7.5?

Tim D

unread,
Jul 1, 2013, 11:29:44 AM7/1/13
to reddot-c...@googlegroups.com
Rendertag syntax has updated between versions. A lot has changed in the last 3 major version releases. Please consider upgrading.
Reply all
Reply to author
Forward
0 new messages