1.3 feature inquiry

Topics: General
Oct 21, 2011 at 9:28 PM

Was curoius if 1.3 got this feature added - My sites have the name of the site appended to the title of every page. I'd like to be able to customize this, or remove it. pretty simple things, but I don't see a way to do it in 1.2.


Oct 21, 2011 at 9:31 PM

It's in Document.cshtml. You can override it in your theme.

Oct 21, 2011 at 9:34 PM

Thanks S., I was curious if this has become configurable from the UI though, sounds like it hasnt. The current default configuration is not very SEO friendly, depending on what you are trying to accomplish. I'll use the document.cshtml edit for now.



Oct 22, 2011 at 8:11 PM

Also take a look at this feature request: http://orchard.codeplex.com/workitem/18179

Nov 11, 2011 at 8:08 PM

Gents, I actually discovered there is a bug in 1.2 for this:

In Document.cshtml, the line:


var title = (Request.Path.TrimEnd('/') != Request.ApplicationPath.TrimEnd('/') && HasText(Model.Title)
                    ? Model.Title + WorkContext.CurrentSite.PageTitleSeparator
                    : "") + WorkContext.CurrentSite.SiteName;


Is missing the portion in red. This causes the site to fail formatting the title correctly if it is run as a root website (not under an app directory..)

So, the solution I was looking for, was actually being caused by a bug!



Nov 11, 2011 at 9:21 PM

Thanks for investigating this. Can you please open a bug so that we can take the fix in? Thanks.

Nov 11, 2011 at 9:54 PM

I created item 18218 for this.