Need to access/extract packageID value from plugin

  • Mark
    Newbie 12 points
    August 16, 2016 at 12:50 pm

    Hi There,

    I am trying to access the packageID value within a plugin namely “NextScripts: Social Networks Auto-Poster”

    First off I’m a novice when it comes to php coding, so please forgive any newbie errors.

    I am adding social media auto posting to the excellent Classifieds theme, which this script does pretty well. However I need to be able to filter at a package level which it currently doesn’t appear to do (not yet anyway). I think I can achieve it by adding an if statement in the appropriate place in there main php script.

    Could someone let me know how I can extract the packageID value (listing package chosen), I’ve tried

    $packageID_value = get_post_meta($postID,’packageID’,true);
    echo $packageID_value;

    and a few variations of with no success.

    I’m guessing as it’s not a core plugin I need to either use a different ID or set a global variable first.

    Any and all help would be much appreciated. Thanks.

    Oh and if anyone knows an alternate solution that will allow me to autopost to social media (Facebook and Twitter mainly) at a listing package level that’d be great too.

  • Josh
    Super Guru 13,875 points
    August 16, 2016 at 1:37 pm

    Hello Mark,
    Please go to Theme Setup >Listing Setup >Listing Packages,click on the + sign to view package ID

    You must be logged in to view attached files.

  • Mark
    Newbie 12 points
    August 16, 2016 at 1:43 pm

    Thanks Josh for your reply.

    Sorry didn’t explain very well, I need to extract the value of the current packageID of the listing the user is currently creating from within the php code of a plugin.

Viewing 3 posts - 1 through 3 (of 3 total)

New Business Themes for WordPress 2020

Start your new website today!

View Business Themes