Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
page_url
I was going to post this in the Existing issues forum but there’s no link to create a new post.
In the official 4.0.5 release, when a site resides in a subdirectory, there’s no way to output the complete page address using txp tags.
<txp:site_url /><txp:page_url />
returns http://domain.tld/directory/directory/url/scheme/
The problem lies with the page_url
which returns the directory name.
Last edited by colak (2007-09-04 06:23:51)
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: page_url
So is the above behaviour a bug or feature?
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: page_url
As you use it, it’s a feature. Without attributes, page_url returns the request_uri, which is always relative to the domain root, not the textpattern root. Is this a request for a type="uri"
attribute that would output the complete URI?
Offline
#4 2007-09-05 13:10:03
- Mary
- Sock Enthusiast
- Registered: 2004-06-27
- Posts: 6,236
Re: page_url
Yep, feature/intentional. Feature request?
Offline
Re: page_url
I’m not really using it but I was trying to help wspence in the forum. After posting there, I thought I should check it out in my install and discovered the behaviour there.
I could see of some other uses where this could be helpful apart from the post to wspence
- bookmarklets could be coded with generic txp tags as opposed to having to hand code the domain
- There are times that someone might want the url to appear on the page (when someone is printing a page for example)
If it is not hard to add functionality in the core it would probably be a welcome addition by many users.
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline
Pages: 1