MAGNOLIA CMS - cmsu:simpleSearch 在作者实例中工作,但在公共实例中不返回任何结果
我使用以下代码来显示我的搜索结果。
<c:if test="${!empty param.SearchName}">
<h1>Results for "${fn:escapeXml(param.SearchName)}"</h1>
<ol>
<cmsu:simpleSearch query="${param.SearchName}" var="results" startLevel="1" />
<c:if test="${empty results}">
<p>No results could be found</p>
</c:if>
<c:forEach var="node" items="${results}">
<li>
<span class="pageTitle"><a href="${pageContext.request.contextPath}${node.handle}.html">${node.title}</a></span>
<a href="${pageContext.request.contextPath}${node.handle}.html"><p class="snipet"><cmsu:searchResultSnippet query="${fn:escapeXml(param.SearchName)}" page="${node}" chars="120"/></p></a>
</li>
</c:forEach>
</ol>
</c:if>
它在作者实例中工作正常,但由于某种原因,公共实例中返回的结果集始终为空。
条件始终返回 true。
知道这个问题来自哪里吗?
预先感谢,A.
I am using the following code to display my search results
<c:if test="${!empty param.SearchName}">
<h1>Results for "${fn:escapeXml(param.SearchName)}"</h1>
<ol>
<cmsu:simpleSearch query="${param.SearchName}" var="results" startLevel="1" />
<c:if test="${empty results}">
<p>No results could be found</p>
</c:if>
<c:forEach var="node" items="${results}">
<li>
<span class="pageTitle"><a href="${pageContext.request.contextPath}${node.handle}.html">${node.title}</a></span>
<a href="${pageContext.request.contextPath}${node.handle}.html"><p class="snipet"><cmsu:searchResultSnippet query="${fn:escapeXml(param.SearchName)}" page="${node}" chars="120"/></p></a>
</li>
</c:forEach>
</ol>
</c:if>
It works fine in the Author instance but for some reason the result set returned in public instance is always empty.
The condition always returns true.
Any idea where this issue is coming from?
Thanks in advance, A.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
Danilo Ghirardelli 提出了 2 个想法 这可能是问题的根源:
和/或在没有匿名访问权限的存储库中进行查询搜索。
经过检查这些可能性:
我停用并重新激活了整个网站,它确实有效!
3.a 在作者实例的管理面板中,导出“The-Insider”根页面中的所有页面
3.b 在公共实例的管理面板中,删除所有页面
3.c 在公共实例的管理面板中管理面板,激活“The-Insider”根页面上的更改
3.d 在公共实例的管理面板中,导入您在步骤 3.a 中生成的 xml 文件
A.
2 ideas were suggested by Danilo Ghirardelli that could be the source of the problem:
and/or query searching in repositories that have no anonymous access.
After checking those possibilities:
I deactivated and reactivated the entire website and it did work out!
3.a In Author Instance's admin panel, export all the pages from the "The-Insider" root page
3.b In Public Instance's admin panel, delete all the pages
3.c In Public Instance's admin panel, activate changes on the "The-Insider" root page
3.d In Public Instance's admin panel, import the xml file you generated from step 3.a
A.