On Mar 2, 2009, at 12:21 AM, Lukas Renggli wrote:
Yes, I know I can do that but I would really rather be able to map
login
(or, for that matter, potentially any command) to an arbitrary URL.
That works on an arbitrary Pier URL, not just on the root. You just
have to add '?command=PULogin'.
Or do I misunderstand your question?
I specifically do *not* want to add '?command=PULogin' to the url.
For the Pier sites that I am deploying, I do not want there to be a
login link on any of the pages. There is no functionality (like wiki
pages) for normal users. Only two or three administrators have
logins (i.e. >0.1% of people accessing the site). Since there is no
login link, I need to be able to give them a URL to be able to login
and I want to give them as simple a URL as possible. In fact, the URL
right now is /site/login and I have been thinking about adding an
Apache rewrite rule to have /login redirect to /site/login.
Does that better explain what I am trying to accomplish?
Now that I'm writing this email I realize that I could just use a
rewrite rule to add '?command=PULogin'--which I might go ahead and do--
but it still seems to me that it would be useful to map an arbitrary
URL to a command without the '?command=' and without having to resort
to Apache rewrite rules.
And while we are on the subject of commands and rewrite rules, I've
noticed that commands post to '/' even if they are part of a longer
URL (like
mydomain.com/site/login). This behavior is slightly
problematic given that the default page for one of my sites is not '/'
and I have a rewrite rule to redirect '/' to that default page. I had
to add a 'RewriteCond %{REQUEST_METHOD} !POST' test to my rewrite
rule. It would be nice if commands posted to the URL they were called
from.
David
----
1 Squeak/Seaside/Pier site deployed