Hide Published Date From ViewSource

Topics: Customizing Orchard, General
Aug 31, 2015 at 8:17 PM
Edited Aug 31, 2015 at 8:19 PM
Problem:
I don't want my articles to show any date as I want them to be evergreen. Through CSS manipulation I was able to suppress display of Published Date, which is great. However, the published date still shows up if you do a "view source" on the page. As a result when someone google's for my articles, SERP shows the published date. That is really bad for my business as that makes my article look really dated.

Question:
How do I remove published date altogether? But it only needs to be done for articles and not for blogs. I do want my blogs to have dates.

Here's an example of Published date that shows up in view source:
        <div class="metadata">
            <div class="published">Monday, October 20, 2014 3:39:00 PM</div>
        </div>

Thanks
Developer
Aug 31, 2015 at 8:43 PM
In your theme, you can update your Placement.info file to not render the Parts_Common_Metadata shape for the BlogPost content type. For example:
<Match ContentType="BlogPost">
    <Place Parts_Common_Metadata="-"/>
</Match>
You can read more about placement here: http://docs.orchardproject.net/Documentation/Understanding-placement-info
Sep 2, 2015 at 4:40 AM
sfmskywalker,

I actually need Blogs to display date. What I did in the placement.info is to add the following:
<Match DisplayType="Detail">
    <Place Parts_Common_Metadata="-"/>
</Match>
<Match DisplayType="Summary">

    <Place Parts_Common_Metadata="-"/>
</Match>
That seems to have worked. Now the articles do not have dates in the "view source". But, it has also introduced some issues in RSS.
The articles RSS feed is now using CreatedDate for <pubdate>, although the articles are coming sorted by the "true" publish date - which is good.

Do you know if this is a bug or whether this is per design, that is, <pubdate> to show createdDate.

Another strange thing I noticed: I removed my config changes but the RSS feed is still using "createdDAte" for <pubdate>. I was expecting the real published date to show up
Why is that?
Thanks