Skip to Content.
Sympa Menu

lyceum-users - Re: [Lyceum-users] Rewrite and xmlrpc.php

lyceum-users AT lists.ibiblio.org

Subject: Lyceum-users mailing list

List archive

Chronological Thread  
  • From: John Joseph Bachir <jjb AT ibiblio.org>
  • To: Paul Hagstrom <hagstrom AT bu.edu>
  • Cc: lyceum-users AT lists.ibiblio.org
  • Subject: Re: [Lyceum-users] Rewrite and xmlrpc.php
  • Date: Tue, 5 Sep 2006 01:36:29 -0400 (EDT)

you fixed xmlrpc! you are a hero!!

i was going to add it to the ticket but i see you've already made comments. paul, is the info you gave here state the latest and greatest?

http://source.ibiblio.org/trac/lyceum/ticket/253



On Tue, 5 Sep 2006, Paul Hagstrom wrote:

I also noticed the xmlrpc.php problem and posted my solution to the
wiki (perhaps that's not the proper way to go about it, I'm new to
the Lyceum community).

What I posted is here:

http://wiki.lyceum.ibiblio.org/index.php/Workarounds

And what it says is basically this:

Add

RewriteRule ^([^/]+)/xmlrpc.php /blog/xmlrpc.php?b=$1 [L]

to your .htaccess file (although you need to fix the redirection URL
to match your setup if your blogs are somewhere other than /blog).
That will get xmlrpc.php to run, but I also found that I needed to
make a change to xmlrpc.php to make it multi-blog aware. I use ecto
on the Mac to post, and I use the MovableType API, so I only fixed
the one spot that was giving me trouble in xmlrpc.php, which is in
the retrieval of categories -- as distributed, .33 retrieves all
categories from all blogs when a category is requested. I changed a
line around line 900 from this:

if ($cats = $wpdb->get_results("SELECT cat_ID, cat_name FROM $wpdb-
>categories", ARRAY_A)) {//lyceum; TODO make multi-blog

to this:

if ($cats = $wpdb->get_results("SELECT cat_ID, cat_name FROM $wpdb-
>categories WHERE blog = ".$blog, ARRAY_A)) {

and now it seems to be working just fine. I'm sure that there's an
analogous change you can make for the other APIs as well.

The association between posts and blogs is mediated by the category/
categories a post belongs to, so as long as the post is assigned a
category in the right blog, it should show up where you expect it
to. So, as long as xmlrpc.php retrieves only the categories from the
appropriate blog, posting via XMLRPC should work. At least it works
with ecto, I haven't tried anything else.

I haven't stress-tested this yet, but it's worked pretty much
perfectly in my initial tests..

I did, by the way, also post these to the bug database as well..

-Paul



Hi all!

Rewrite rules does not process urls like .../xmlrpc.php
For this reason external authoring applications like FF's addon
Deepest Sender (https://addons.mozilla.org/firefox/1811/) does not
work :(

--
Regards, Al
http://blogs.tks.ru/

_______________________________________________
Lyceum-users mailing list
Lyceum-users AT lists.ibiblio.org
http://lists.ibiblio.org/mailman/listinfo/lyceum-users


--
John
----
aim/yim/msn/jabber.org: johnjosephbachir
713.494.2704
irc://irc.freenode.net/lyceum
http://lyceum.ibiblio.org/
http://blog.johnjosephbachir.org/




Archive powered by MHonArc 2.6.24.

Top of Page