Zope: failed kludge around Plone hardcoding

K

Kyler Laird

I'm trying to use Plone again. I do this every few months and usually
drop it after a few days. I keep getting a little closer though. I'm
documenting one of my attempts to make Plone more palatable in case
someone else comes this way (and so that I'll remember).

Plone uses random capitalization everywhere but the place that bothers
me most is "Members". While other uses can be changed or hidden,
"Members" is hardcoded all over and it's likely to appear in URLs I
want to share.

I decided that getting rid of "Members" is not an option. It'll break
way too many things that I don't even want to consider. Instead, I am
trying to work around it with a PortableHole.
http://www.zope.org/Members/TheJester/PortableHole/

To do this, I created a PortableHole in my Plone folder. It's called
"members" and points to "/portal/Members". (Make sure to specify the
full path even from within a VirtualHost.)

Next I edited portal_actions, changing "Members" to "members". That
changes the tab along the top, but I found that when I visited
/members without authenticating, I received an error. I could still
get to individual member folders, but I couldn't generate the
member_search_form.
Unauthorized: You are not allowed to access meta_type in this context

As a test, I gave Members/index_html some proxy roles. That didn't
help. Next I changed it to call the form in Members/.
<dtml-return "Members.member_search_form()">
That did work. At least it generated the form and the form did get
results. The problem is that the results point to "Members/" URLs.

So...I decided to take another approach. I removed my "members"
PortableHole and renamed "Members" to "members". I then created a
new PortableHole named "Members" that points to "members". (This is
just the opposite of the way it had been.)

I returned members/index_html to its default setting and now the form
worked, but the results had URLs of the form "Members/members/kyler".
Ug. It looks like getHomeUrl() is to blame. Also, I tried adding a
new member and the new person was created but the default folders were
not created (correctly).

I'm giving up for now. As a temporary workaround I added
RewriteRule ^/members(.*)$ /Members$1
to my Apache configuration so that I can at least post reasonable URLs.

For my next attempt I suspect that I should use "Members" as the real
folder and overload getHomeUrl() to use "members". I'm not sure how to
do that reasonably.

--kyler
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top