• This script allows every post that you publish on your WordPress blog to also be reflected (or added) to your LiveJournal blog automatically. This script only emulates publishing to your LJ blog, you cannot edit LiveJournal entries once they are published (through the WP admin page). If there is enough interest, I could come up with edit functionality as well as others such as moods and music. Here is a link to the hack instructions.
    The items sent to LiveJournal are your post title, your post content and the date and time of your post. Enjoy.
    Please post bugs to https://dinki.mine.nu/word/

Viewing 15 replies - 1 through 15 (of 51 total)
  • Thread Starter Laughinglizard

    (@laughinglizard)

    There is a little bugfix for this hack. The hack tutorial has been updated.

    Thanks LL for the great script. I an sure this feature will come in handy to those on Lj who want a blog AND their LJ friends….

    there’s somethings i noticed ?? overall it the hack works, which is great. But as in wp how there is the option for the ‘time difference’ the current time is sent to lj wrong… meaning how i write a post @ 11ish my time, and the time differences on wp shows my actual time, yet in lj, it shows that the time is 8ish… my 3hr time difference does not reflect in lj.
    And evertime i post, though it goes through, i get this error when it goes back to post.php
    Warning: Cannot modify header information – headers already sent by (output started at /home/artistia/public_html/ecila/log/my-hacks.php:5) in /home/artistia/public_html/ecila/log/wp-admin/post.php on line 159
    but after a refresh it’s gone… but appears everytime i make a new post.
    You can see the effects here
    https://ecila.artistia.net
    &
    https://livejournal.com/~b0owahaha

    Thread Starter Laughinglizard

    (@laughinglizard)

    I am not sure where the first error comes from. It could be related to you having an extra space or a newline somewhere in your my-hacks.php or in your post.php.
    The current time is sent as the time of your server. This should and can be fixed. As a matter of fact, while I was writing this, I found a quick answer. Look for the fix in the same hack tutorial (just copy the function again)
    Glad you like the hack.
    Peace

    First off, GREAT PLUGIN!. The plugin works great and I did modify it a bit to not crosspost private entries, however I’m having some difficulties when I try to post with a client such as wbloggar. Any suggestions on that? I’ll try to look into myself to see if I can come up with anything. GREAT WORK! ??

    Thread Starter Laughinglizard

    (@laughinglizard)

    Thanks for the positive feedback! In order for the plugin to work through wbloggar (or any other external posting client which uses XMLRPC) follow the tutorial as indicated, but add the following line to xmlrpc.php (found in the root of your blog):
    if ($content) ljautoupdate($content, $post_title);
    Ideally, there are a bunch of places this should be placed, but since it sounds like you are php-aware, put it within the functions that are being used by your bloggar to post to your blog (should be either through the metaWeblog API, the b2 API or the blogger API). That should fix it. If you hace any difficulty, let me know.
    Peace

    I’m not really that “php-aware”, but thanks for the strong encouragement. I’m still having difficulty editing the correct parts of the xmlrpc.php file. I’ve tried adding the code snippet to basically all “new posts” methods in the various APIs but it still does not work. Perhaps I’m doing things wrong. I basically add it after the “$result” line code snippet in the methods. Any help on this would be much appreciated.
    Thanks again.
    w.

    Thread Starter Laughinglizard

    (@laughinglizard)

    You have the technique just right. However, I believe that w.bloggar uses the b2 API to post. In that case, you would need to add this line after the $result in the “wp_insert_post” function found all the way at the top of xmlrpc.php:
    if ($post_content) ljautoupdate($post_content, $post_title);
    Please let me know if it works.
    Peace

    Hi LL.
    Thanks for all of your help, but I guess it just wasn’t meant to be with wbloggar. I tried your suggestion above and it still didn’t work. I even tried to include the my-hacks.php file in the beginning of the page code and that didn’t work either. I verified that I have enabled hacks and it works when I post using the web interface so that’s good. Am I missing something? Have you tried this and gotten it to work? Thanks again.
    w.

    Thread Starter Laughinglizard

    (@laughinglizard)

    I could try to recreate the hack on my site and send you the files. But that will take a while. Keep checking back! ??

    this hack works great, except it seems everything that gets posted to livejournal has extra line breaks in it.
    https://zenandjuice.com/word/ is my wordpress version.
    https://www.livejournal.com/users/zenandjuice/ is my lj.
    Any ideas?

    it seems LJ is applying it’s own auto breaks in addition to WP’s auto breaks.

    Thread Starter Laughinglizard

    (@laughinglizard)

    @zenandjuice: are you using a mac or a linux box when you post your entries? You could try the following and see if it helps:
    Find this inside the ljautoupdate function:
    $lineendings = “pc”;
    And you could try the other variations in place of “pc” , namely:
    “unix”
    “mac”

    I tried this hack and it works great so far. I’m wondering if it’s any way possible to adjust the hack to make each post I make automatically friends only post rather than public one? I find this hack easier to use than when I was on b2. Thanks.

    ah, so u converted! ??
    cool…

Viewing 15 replies - 1 through 15 (of 51 total)
  • The topic ‘AutoUpdate LiveJournal Hack’ is closed to new replies.