WordPress.org

Ready to get started?Download WordPress

Forums

NextScripts: Social Networks Auto-Poster
[resolved] Show where the post was shared (8 posts)

  1. coreykliewer
    Member
    Posted 6 months ago #

    I know in the CMS - there is a link that shows where the post was posted to. - But is there a way to have that information show on the post page?

    For example - if I wrote a blog post about cows, and then shared it onto tumblr - Can I have it show the link of where I posted it to on Tumblr?

    Thanks
    ck

    http://wordpress.org/plugins/social-networks-auto-poster-facebook-twitter-g/

  2. NextScripts
    Member
    Plugin Author

    Posted 6 months ago #

    Plugin does't have such feature, but if you know php/wordpres you can extract this info from custom field and show it via shortcode or something like it.

  3. coreykliewer
    Member
    Posted 6 months ago #

    But that would have to be done for each individual post - correct? Or could that be used in a template?

  4. NextScripts
    Member
    Plugin Author

    Posted 6 months ago #

    Yes, that could be done in the template.

  5. coreykliewer
    Member
    Posted 6 months ago #

    So I am looking at the custom fields - and the one for tumblr says the following : a:1:{i:0;a:13:{s:4:"doTR";s:1:"1";s:12:"apTRPostType";s:1:"T";s:11:"SNAPTformat";s:7:"%TITLE%";s:10:"SNAPformat";s:10:"%FULLTEXT%";s:9:"isAutoImg";s:1:"A";s:8:"imgToUse";b:0;s:9:"isAutoURL";s:1:"A";s:8:"urlToUse";b:0;s:11:"isPrePosted";s:1:"1";s:8:"isPosted";s:1:"1";s:4:"pgID";d:73517101489;s:7:"postURL";d:73517101489;s:5:"pDate";s:19:"2014-01-16 15:45:48";}}

    some things I can figure out - Like I should be using "postURL" but what the other stuff like s:7 and what a:1 mean - I dont know - do you have documentation on this - or can you point give me the string for getting the tumblr postURL

    thanks for your help

  6. NextScripts
    Member
    Plugin Author

    Posted 6 months ago #

    You need to use : "pgID";d:73517101489

    Just add http://YourTumblrName.tumblr.com/post/ to this ID and you will get the link to the post.

  7. coreykliewer
    Member
    Posted 6 months ago #

    I am so sorry, and please forgive my ignorance. I understand, html, css, php and I can program for wordpress - but I dont understand what you mean by "add http://YourTumblrName.tumblr.com/post/ to this ID and you will get the link to the post."

    How do i do that? I created a custom field - but I dont know how to use the "pgID";d:73517101489 as you instructed. I do see that the number 73517101489 is the actual link to the post that I am testing on - but I dont know how you got that number. Its quite unique, and I didnt give it to you.

    And if i need to make a new custom field for every single new post - thats not going to work.

    Thanks for all your help.

  8. NextScripts
    Member
    Plugin Author

    Posted 6 months ago #

    Example:

    $myTumblrURL = 'http://nxtscripts.tumblr.com/'; // Change it to your real URL
    
    $pMeta = maybe_unserialize(get_post_meta($postID, 'snapTR'), true));
    $tumblrPostID = $pMeta[0]['pgID'];
    $linkToTumblrPost = myTumblrURL . "post/" . $tumblrPostID ;

    Most networks correctly return the actual URL of the post in the postURL field.

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.