Add ability to syndicate galleries

Currently post syndication simply copies post content to the remote site. 
That makes [gallery] short code to contain wrong image IDs from the original post.
This patch parses post content, fetches all galleries and upload images to the remote site prior to the syndication. It adjusts gallery code with new IDs and then syndication continues normally.