Is It Possible To Share Post Per User Between two wordpress installations?

7 replies
  • WEB DESIGN
  • |
Hey guys I hope I have the chance to pick someones brain here because I find myself stumped on a project I am working on.

Is it possible to have a user post on an external wordpress installation (on the same server) auto publish to our main website?

We would sync the user data between both wordpress installs and we are trying to sync their post as well. This is not a Multisite setup either. When a user published a post on their blog it will auto publish that post on our blog under their username. Is this far fetched?
#installations #post #share #user #wordpress
  • Profile picture of the author Andrew H
    Definitely not far fetched. If you know PHP and MySQL this could be done.

    Just gotta make some changes to the registration and posting functions to get the users and posts to go into both wordpress databases.

    Alternatively you could setup a cron job to copy the data to the other wordpress db every x minutes/hours/day(s). Might run into some issues with user id's though.
    Signature
    "You shouldn't come here and set yourself up as the resident wizard of oz."
    {{ DiscussionBoard.errors[7810343].message }}
  • Profile picture of the author KingRoyal
    The cron idea sounds interesting, and I know that the idea itself should be relitively simply however a developer I was talking with told me it would take like 25 hours of coding to make it happen lol and I called his bluff. How would you recommend getting a cron to do that?
    User ID's shouldnt be too much of an issue since upon registration the databases syncs users automatically with both the same ID's, ive got that working already. Im just stuck on the post sync strategy. Ive found some post sync stuff out there but they dont seem to work with multiple users.

    Thanks for anymore info you have to offer!
    {{ DiscussionBoard.errors[7810358].message }}
  • Profile picture of the author Andrew H
    To create something custom I think 25 hours is probably on par for a low paid programmer that doesn't specialize in wordpress. Most of the time would be spent fiddling around and debugging unique post ID issues (possibly create a second db table for the copied posts to resolve this issue).

    Personally I don't work with WP a lot, so someone else might have a better idea of the best way to implement this.

    EDIT: Might be easier to just create a connection to the other DB and just read the posts and users directly from there instead of dealing with copying posts.
    http://www.dnexpert.com/2010/04/18/l...ess-databases/
    Signature
    "You shouldn't come here and set yourself up as the resident wizard of oz."
    {{ DiscussionBoard.errors[7810438].message }}
  • Profile picture of the author xtrapunch
    Why do through all the cron stuff? You can use any autoblog WP plugin to pull content from any site's RSS feed. WordPress has separate feeds of things like posts, categories, tags and authors. Use the ones that you want.

    WordPress Feeds « WordPress Codex
    Signature
    >> Web Design, Wordpress & SEO - XtraPunch.com <<
    Web Design & SEO Agency | Serving World Wide from New Delhi, India

    {{ DiscussionBoard.errors[7817657].message }}
  • Profile picture of the author KingRoyal
    Autoblog wont pass images however, and thats going to be a problem in my case.
    {{ DiscussionBoard.errors[7817936].message }}
  • Profile picture of the author SteveJohnson
    What you want is fairly simple in execution - hook a function into the 'save_posts' action that POSTs the post data to a 'listener' on the other site when the post is saved. The other site takes the data and builds and inserts a post on its own site.

    Not a 25-hr job, but it's not a "hello world" endeavor, either.
    Signature

    The 2nd Amendment, 1789 - The Original Homeland Security.

    Gun control means never having to say, "I missed you."

    {{ DiscussionBoard.errors[7819405].message }}
  • Profile picture of the author KingRoyal
    Hey everyone, thanks for the feedback! I ended up getting it figured out. I created a script using XMLRPC to transfer all of the information including images. Works perfect. Thansk!
    {{ DiscussionBoard.errors[7822397].message }}

Trending Topics