Forum Replies Created

Viewing 10 replies - 1 through 10 (of 10 total)
  • Thread Starter midtoad

    (@midtoad)

    hmm. I only had one plug, a Google highlighter, activated, but I disactived it anyway. I then copied xmlrpc.php to xinput.php, and told Ecto to look for that. When it offers to update its cache of articles, it gives the following error:
    A list of blogs could not be retrieved! Please verify the account you created

    Is there anything else I could try?

    thanks.
    S

    Pocket SharpMT works great with WordPress! I just downloaded it and tried it a few minutes ago. Only one change was required. Since my wordpress blog is in a /wp folder off my website root folder, the CGI-BIN path it asks for should be /wp/xmlrpc.php.

    You can see my first post from my PDA with this tool at:
    http://midtoad.homelinux.org/wp/

    Thread Starter midtoad

    (@midtoad)

    There’s an upgrade.php I’m supposed to run? Doh!
    As you said, it works perfectly. Only problem is, it broke all of my customisations. Fortunately I kept copies of the old site, so I should be able to diff the .css files and my index.php. Anything else I need to change?
    thanks
    S

    Ok, I changed my mind on how to deal with categories. I’m trying to debug the wp-mail.php script (maybe I should take this discussion over to the dev area) and I see a problem: it looks for the category from the content of the mail message using a function called xmlrpc_getpostcategory($content). I’ll have to track that down and see how it does it.
    Here’s an excerpt from the wp-mail.php script:

    if ($user_level > 0) {
    $post_title = xmlrpc_getposttitle($content);
    $post_categories[] = xmlrpc_getpostcategory($content);
    if ($post_title == '') {
    $post_title = $subject;
    }
    if (empty($post_categories)) {
    $post_categories[] = $default_category;
    }
    if (!$thisisforfunonly) {
    $post_title = addslashes(trim($post_title));
    $content = preg_replace("|\n([^\n])|", " $1", $content);
    $content = addslashes(trim($content));
    if($flat > 500) {
    $sql = "INSERT INTO $tableposts (post_author, post_date, post_content, post_title, post_category) VALUES ($post_author, '$post_date', '$content', '$post_title', $post_category)";
    } else {
    $sql = "INSERT INTO $tableposts (post_author, post_date, post_content, post_title, post_category, post_lat, post_lon) VALUES ($post_author, '$post_date', '$content', '$post_title', $post_category, $flat, $flon)";
    }

    FYI all of this. I can’t work on this any more for a day or two…

    Hey! that didn’t take long. The damn thing works!
    Using phpMyAdmin (anyone reading this that is not already using this fantastic tool, get it NOW!), I posted the erroneous SQL into the SQL window for the wp_post table. I was immediately able to see that it was not the trailing comma <i>per se</i> that was the problem, but the missing post category that should come after it.
    Now here’s the rub. The wp-mail script as it stands is not set up to parse out a category. So what to do? The easiest thing, though a bit of a kludge, is to edit the wp-mail script so that it writes a category into the SQL. But what category? ‘General’ would be a good idea. Or maybe one could create a new ‘mobile’ category and write out its category number (check the database for that). I’m going with the former.
    You can see the first mobile post on my site, here .

    After fixing the above bug, I see a couple of things that are needed to make this work. (after I get this all worked out, a Tutorial might be in order).
    In the Options settings, the user and ID to set are those for the account where you will send the messages that contain your posts. In the first line of the message itself, you have to enter a userID:password, and this should be for a user that has permission to post on your blog (let’s call it ’email’). I recommend setting up a separate user just for mobile postings, since the userID and pwd are transmitted in clear-text in the message.
    After sorting out all of the above, I got success! (sort of). When I open wp-mail.php script in a browser, or run “php wp-mail.php” in a shell prompt, I see that the latest message in the ’email’ account has been processed by the script, that the user ID and password, as well as the subject and contents of the message were extracted, and that the script also deleted the message – good, that way the account is self-flushing.
    However, the script also writes SQL to insert the latest message into the WP database, and this SQL has an error in it:
    [You have an error in your SQL syntax near ‘)’ at line 1]
    INSERT INTO wp_posts (post_author, post_date, post_content, post_title, post_category) VALUES (3, ‘2004-05-07 16:25:02’, ‘First post by e-mail! This means that I can now blog from just about anywhere there is internet coverage or cellular coverage. Great!’, ‘First post by e-mail!’, )
    I suspect that the trailing comma might be the error, and will investigate.

    There appears to be a bug in the file class-pop3.php, so that it returns the wrong answer when provided by the +OK status that a NOOP request makes. This was apparently found as far back as September 2003, when WP was b2, and the bug has been carried forward. Read this post (which I found out about on Google).

    Hey! nobody told me I’d have to use vi to get this going! (ever notice that ‘vi’ are the first two letters in the word ‘vile’? )
    Anwyay I created a crontab command:
    15,30,45,0 * * * * GET http://midtoad.homelinux.org/wp/wp-mail.php
    It’s running every fifteen minutes, but the output is the following:
    Can’t locate object method “init_header” via package “HTTP::Headers” (perhaps you forgot to load “HTTP::Headers”?) at /usr/lib/perl5/site_perl/5.6.0/HTTP/Message.pm line 189
    Does that look at all familiar?

    good ol’ cut & paste is what I use! simple but effective.

    Forum: Fixing WordPress
    In reply to: Bug database?

    I’ve used Mantis and it only takes a few min. to set up. Are you needing a volunteer? πŸ™‚

Viewing 10 replies - 1 through 10 (of 10 total)