2013-07-15 2 views
0

우리 URL 목록을 제공하는 데 사용되는 다음과 같은 코드가 있습니다레드 닷에서 목록 항목에 대한 깨끗한 URL을 얻으려고 노력 CMS

<reddot:cms> 
                <foreach itemname="childPages" object="Context:Indexes.GetIndexByPageId(Guid:021743AA8509473C9615A4BA5C2BAC32).SubIndexes" countername="pageCounter"> 
                <htmltext><dd><a href="<%!! Store:childPages.GetUrl(Bool:True) !!%>"><%!! Store:childPages.Headline !!%></a></dd></htmltext> 
                </foreach> 
</reddot:cms> 

및 <퍼센트에서 깨끗한 URL을 반환 할! 저장소 : childPages.GetUrl (BOOL : 참)! %> 그래서 http://www.mysite.com/thispage.htm이 내가 시도 http://www.mysite.com/thispage로 게시되어

<reddot:cms> 
                <foreach itemname="childPages" object="Context:Indexes.GetIndexByPageId(Guid:4595E6AE30D243E6AB11DAE0553A90B7).SubIndexes" countername="pageCounter"> 
                <htmltext><dd> 
<% 
DocSectionURL = "<%!! Store:childPages.GetUrl(Bool:True)!!%>" 
DocNewSectionURL = Replace(DocSectionURL,".htm","") 
%> 
<a href="<% response.write(DocNewSectionURL) %>"><%!! Store:childPages.Headline !!%></a></dd></htmltext> 
                </foreach> 
</reddot:cms> 

하지만 www.mysite.com/thispage.htm 여전히 반환됩니다. 누구든지이 일을 시도하는 가장 좋은 방법을 제안 할 수 있습니까? 비슷한 메서드를 자리 표시 자와 함께 사용하도록했지만이 RQL에서는 작동하지 않습니다. 미리 감사드립니다.

답변

1

PreExecute 또는 Rendertags에서이 작업을 수행 할 수 없습니다. 최종 URL은 RenderTags 및 PreExecute가 실행 된 후에 만들어집니다.

확장명이 ".htm"이 아닌 파일을 게시 할 수 있으며 (설정에 확장명으로 "."을 삽입하거나 전달 서버에서 PHP/ASP/ASPX/...를 통해 URL을 조정할 수 있습니다. 아파치, IIS, DS 등).

최고, 힐마 번즈