Page 1 of 2

Myspace XML-RPC

Posted: Tue Jan 10, 2006 9:35 am
by gmcle454
Is it possible to duplicate a s9y post into myspace? If so how? Is there something like the LJ-Update plugin that I could use?

Re: Myspace XML-RPC

Posted: Tue Jan 10, 2006 10:44 am
by garvinhicking
You would need to create a new plugin; the LJ-Update plugin could help as a foundation for that.

There is no abstract way of cloning posts, because each provider has their own API usually. Maybe myspace has a RSS import?

Regards,
Garvin

Posted: Tue Jan 10, 2006 2:49 pm
by Guest
thanks for the quick reply, I'll look into it.

Posted: Wed Jan 11, 2006 5:22 am
by gmcle454
I found this php script for WordPress and this hack for WordPress. Both are in PHP.

Unfortunately, I'm **VERY** new to PHP, so this may be a dumb question. Is it possible to modifying these scripts, and where would I start if I were up for such a challenge?

Posted: Wed Jan 11, 2006 2:05 pm
by garvinhicking
Yes, I guess you could port these scripts with some effort.

Wait a moment and I'll port the scripts for you.

Best regards,
Garvin

Posted: Wed Jan 11, 2006 2:25 pm
by garvinhicking
You can overwrite your LJ Update plugin with this file:

http://nopaste.php-q.net/183805

Then you can configure the LJ Update plugin to use "MySpace" posting. Your PHP provider needs to support CURL functionality for this to work!

Best regards,
Garvin

Posted: Wed Jan 11, 2006 2:49 pm
by Guest
I am already using the LJUpdate. Can I copy the plugin installation and then make the modifications to the new copy? or will that bork something? CURL is enabled with my host.

Posted: Wed Jan 11, 2006 2:52 pm
by garvinhicking
How do you mean that? Do you want to publish your entries to BOTH LJ AND MySpace?

I would suggest you to consider this :) Currently, you cannot use both postings methods in conjunction, because you can only install that plugin once.

If I misunderstood you and you only want to use MySpace posting: Just edit the existing serendipity_event_ljupdate.php file and paste the code from the link above.

HTH,
Garvin

Posted: Wed Jan 11, 2006 7:38 pm
by Guest
I do want to post both places (LiveJournal and MySpace) simultaniously when I update my s9y blog. Unfortunalely, I've got friends on both who want to keep read it through their respective friends/subscriptions system. I wish they would just come to my site, but they are set in their ways.

Is this not possible?

Posted: Thu Jan 12, 2006 11:51 am
by garvinhicking
Can you try to install the plugins two times (from the s9y plugin configuration panel - not copying the plugin core files twice)? Reading the code, this seems to be possible. Then you can configure the one plugin to post to LJ and the other plugin to post to MySpace...

Best regards,
Garvin

Posted: Thu Jan 12, 2006 2:42 pm
by Guest
I somehow managed to install twice--I think. It shows up twice in my configure plugins panel, but there is not a second directory in the file system. The settings now have a pull-down menu for myspace or lj. I've put in appropraite infor for each, and lj is still working perfectly. But nothing has shown up in myspace yet.

Should there be a second ljupdate directory in the plugins directory?

I need to make sure I've got the right myspace server.

Posted: Thu Jan 12, 2006 3:16 pm
by garvinhicking
No, one directory is perfectly fine. That's how I meant it.

If the posting does not show up in myspace, it might be because the original script you linked to can be buggy. There's no debugging output in the LJ plugin, but that can easily be added.

Please try this file, which contains information about what's going on:

http://nopaste.php-q.net/184043

Best regards,Garvin

Posted: Thu Jan 12, 2006 4:28 pm
by Guest
I pasted that code into the ljupdate.php file and it broke s9y

Posted: Thu Jan 12, 2006 4:52 pm
by garvinhicking
That does not help me much. Which kind of error do you get? :-)

Did you properly paste the code? Maybe you introduced additional linebreaks or uploadde the file wrongly.

Regards,
Garvin

Posted: Thu Jan 12, 2006 6:25 pm
by Guest
Here's the error:

Code: Select all

Parse error: parse error, unexpected '.' in /home/content/g/m/c/gmcle454/html/serendipity/plugins/serendipity_event_ljupdate/serendipity_event_ljupdate.php on line 205
I downloaded the file and opened it in DreamWeaver (the same program I've used to do all the other modifications to my journal and design my site)
I selected everything and deleted it, then pasted in your code from the link you sent.