• Hi and Good day,

    I am trying to display my post content inside shortcode and everything working well except now the auto-adding links from your plugin is not working anymore, i am sure its either a theme or plugin, but thought will ask you in case you have faced similar issue before.

    thanks in advance.

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Lucian Apostol

    (@thedark)

    Hello. Auto Affiliate Links hooks on the_content filter. So, if the post content is displayed with shordcodes or with other template functions, it will not work.

    Adding a filter when shortcodes are displayed will probably mess with a lot of other stuff, as shortcodes are usually used to display scripts or specific parts of content that I dont think Auto Affiliate Links should mess with.

    Theoretically, I can add a filter to do_shortcode_tag hook, and check for a specific parameter that should have been previously given to the shortcode, but that will add an unnecesary check for every shortcode output.

    If you are writing your own shortcode functions that display the content, you can pass the content trough wpaal_add_affiliate_links function, by sending the content as the only parameter. The function will return the content with the links inside, but it will only work if all the checked settings are right, for example, if it is in the main loop of the content output, if the page where it is used is a post page, and the custom post type is checked in settings.

    Thread Starter kindghost22

    (@kindghost22)

    Thanks alot for your reply, i have understood the issue now and found an alternative JS involve soloution.

    May i know if you are willing to customize your plugin with smaller version of it and to do more specific tasks, let me know how i can contact you to discuss more on this?

    thanks,

    Plugin Author Lucian Apostol

    (@thedark)

    Thank you. contact [at] autoaffiliatelinks [dot[ com or use the contact form on our website autoaffiliatelinks.com

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Links are not added to post content load using php template inside shortcode’ is closed to new replies.