Hi Daniel

If you want to try RQL have a look at the listnames query. This is
from the RQL documentation:

"Use this RQL query to list all file names of existing pages in a
project.

You assign file names to determine the file name of a published page.
When no file name is assigned, the page is published using the page ID
or page GUID as a file name."

Query Example:

<IODATA loginguid="[!guid_login!]" sessionkey="[!key!]">
  <PROJECT>
    <PAGES action="listnames"/>
  </PROJECT>
</IODATA>

Server Response:

PAGE:   The PAGE element is repeated for every page with a file name
guid:   GUID of the page
headline:       Headline of the page
name:   File name of the page

Example Response:

<IODATA>
  <PAGES>
    <PAGE guid="[!guid_page!]" headline="page headline"
     name="filename.htm" />
    ...
  </PAGES>
</IODATA>

So you would use the guid of the page you are checking to get the file
name of the page. Hope this helps.

Cheers - Aaron


On Jul 16, 10:30 pm, Daniel <[email protected]> wrote:
> Hello all,
>
> I want to use some PreExecute Code or RenderTag in a PageTemplate to
> prevent a part of the template of being published, if the Filename of
> the published file does not match a certain extension. I tried
> different things to have this work, but every single try failed with
> the same result.
>
> I tried the following:
> - Render Tags: Context:CurrentMasterPage.GetUrl().EndsWith(Str:php)
> - Prexecute substr() combined with the
> Context:CurrentMasterPage.GetUrl()
> - Prexecute substr() combined with an info element "Page: Published
> file name"
>
> The point is that "Context:CurrentMasterPage.GetUrl()" or the info
> element use to return the correct filename as long as I use it alone
> or write it directly to the page via an echo for example. But if I use
> the rendertag EndsWith-method, or the php substr (or any other), then
> the URL or page name string gets changed in a string like this:
> /*--IOHREFBEGIN linkguid=GUID pageguid=GUID projectvariantguid=GUID
> languagevariantguid=GUID islink=1 type=1002 subtype=20*//*--IOHREFEND-
> */
>
> If someone out there has an idea how I can solve this, or why RedDot
> does behave like this, or how I can get around this behavior, I will
> be more than happy.
>
> Best regards,
> Daniel

-- 
You received this message because you are subscribed to the Google Groups 
"RedDot CMS Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/reddot-cms-users?hl=en.

Reply via email to