Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
Force a section to use a page?
Can this be done?
I’ve just worked on another CMS where I could force the page to display using a second template using a query string (?template=newpage).
For example you could have the page set to use a holding page to the public, but send the url to the client with the query string and he would see the actual site.
Offline
Re: Force a section to use a page?
soo_if_frontpage and glx_if should be of help unless you want to deconstruct a set of conditionals
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline
Re: Force a section to use a page?
Hey colak – thanks for the reply – I know it can be done in other ways…. but just adding a query string with the required page just seems, logical (to me)
Offline
Re: Force a section to use a page?
Since you can delegate an entire page template to a single form or group of forms, that’s what I’d do. Use adi_gps to handle the query string. Then call the desired form based on the name in the query string.
Offline
Re: Force a section to use a page?
This kinda works in the messy mode: ...?id=1&s=public
will use the page template associated with the section public
to display the article.
Offline
Re: Force a section to use a page?
etc wrote:
This kinda works in the messy mode:
...?id=1&s=public
will use the page template associated with the sectionpublic
to display the article.
That’s a bug which allows off-loading articles in different page templates, by-passing any page template code. It has been fixed in r3759 (TXP v4.5.0).
Last edited by Gocom (2012-06-13 10:24:22)
Offline
Re: Force a section to use a page?
IIRC you can force a section, or just an url-word as pseudo-section, to use a page template using gbp_permanent_links.
Last edited by jakob (2012-06-13 11:42:33)
TXP Builders – finely-crafted code, design and txp
Offline
Re: Force a section to use a page?
Gocom wrote:
That’s a bug which allows off-loading articles in different page templates, by-passing any page template code. It has been fixed in r3759 (TXP v4.5.0).
Will then be possible to somehow protect an entire section with <txp:password_protect />
? Sorry for off-topic.
Offline
Re: Force a section to use a page?
etc wrote:
Will then be possible to somehow protect an entire section with
<txp:password_protect />
? Sorry for off-topic.
If that is the only issue that allows by-passing template code, then yes, you could use tags as <txp:password_protect />
with confidence just by placing such tag/code to a section’s page template.
Offline
Pages: 1