Reply to thread

Various entities (XF:AbstractNode, XF:User) implement method isSearchEngineIndexable.


However, there is no formal interface for that and and at least to me it seems to be nice to have one.


If such an interface existed, it would be possible to set a page var mainContentEntity or smth. like that and have noindexind handled  automatically instead of having to repeat code like code


[code]

<xf:if is="!$thread.isSearchEngineIndexable()">

    <xf:head option="metaNoindex"><meta name="robots" content="noindex" /></xf:head>

</xf:if>


<xf:if is="!$user.isSearchEngineIndexable()">

    <xf:head option="metaNoindex"><meta name="robots" content="noindex" /></xf:head>

</xf:if>


<xf:if is="!$forum.isSearchEngineIndexable()">

    <xf:head option="metaNoindex"><meta name="robots" content="noindex" /></xf:head>

</xf:if>


<xf:if is="!$category.isSearchEngineIndexable()">

    <xf:head option="metaNoindex"><meta name="robots" content="noindex" /></xf:head>

</xf:if>

[/code]


Back
Top Bottom