Wordpress + trading script question

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mezotar
    Registered User
    • Dec 2014
    • 4

    #1

    Wordpress + trading script question

    Hi there,

    can anyone tell me how to make Wordpress and a trading script (Pulse Trade or ATC) work together? I can enable incoming hits counting easily but i dont know how to control outgoing traffic..Thx.
  • Miguel T
    ♦ Web Developer ♦
    • May 2005
    • 12473

    #2
    Change templates...
    Where it has <?php the_permalink(); ?> , you should probably have something like:

    your-trade-script/out.php?url=<?php echo get_permalink($post->ID); ?>

    Full Stack Webdeveloper: HTML5/CSS3, jQuery, AJAX, ElevatedX, NATS, MechBunny, Wordpress

    Comment

    • AdultSites
      Confirmed User
      • Feb 2015
      • 203

      #3
      You can get info at forum on their site (Trade Pulse).

      Comment

      • mezotar
        Registered User
        • Dec 2014
        • 4

        #4
        Thx. for replies!

        AbsolutePorn wrote:
        Change templates...
        Where it has <?php the_permalink(); ?> , you should probably have something like:

        your-trade-script/out.php?url=<?php echo get_permalink($post->ID); ?>
        I've looked everywhere but can't find this code. When you say "templates", do you mean "Page Tamplate" or "Main Index Tamplate" or some other one?
        Other than that i tried to change permalinks in WP Settings and it works to some degree. I just can't specify gallery link because it seems to fail read double slash "//" which is needed in the script link "cgi-bin/atc/out.cgi?s=60&u=http (gallery)"


        AdultSites wrote:
        You can get info at forum on their site (Trade Pulse).
        Firstly i should say i don't use Pulse, I meant it as an example of trading script. I use AT Core and i thought it would have similar solution. And it actually works...but again only to some degree..

        Go to jquery.com and download latest version, upload it to yourdomain.com/js/jquery.js

        Add this code between <head></head> tags:
        Code:

        <script type="text/javascript" src="/js/jquery.js"></script>


        This code will include jquery library.


        Add this code between <head></head> tags:
        Code:

        <script>
        jQuery(document).ready(function(){
        jQuery("a").click(function(){
        url=jQuery(this).attr('href');
        jQuery(this).attr('href','/tp/out.php?p=100&link=click&url=' + escape(url));
        });
        });
        </script>
        It then turns every link on the site to trading links, which is undesirable in case of navigation for example, but more importantly it has a problem with reading "&" sign, which it translates to something like "%2A" in url. Therefore the url of gallery isnt recognized and visitor can't open video. I'm no expert in url enconding and stuff like that so i have no idea what to do about that.

        Comment

        • WDRockstar
          Registered User
          • Jan 2015
          • 50

          #5
          Originally posted by mezotar
          Thx. for replies!

          AbsolutePorn wrote:

          I've looked everywhere but can't find this code. When you say "templates", do you mean "Page Tamplate" or "Main Index Tamplate" or some other one?
          Other than that i tried to change permalinks in WP Settings and it works to some degree. I just can't specify gallery link because it seems to fail read double slash "//" which is needed in the script link "cgi-bin/atc/out.cgi?s=60&u=http (gallery)"


          AdultSites wrote:

          Firstly i should say i don't use Pulse, I meant it as an example of trading script. I use AT Core and i thought it would have similar solution. And it actually works...but again only to some degree..



          It then turns every link on the site to trading links, which is undesirable in case of navigation for example, but more importantly it has a problem with reading "&" sign, which it translates to something like "%2A" in url. Therefore the url of gallery isnt recognized and visitor can't open video. I'm no expert in url enconding and stuff like that so i have no idea what to do about that.

          Modifying that last code, you can place additional classes to the <a> tag so that only a's with a class you specified will the only ones targeted by jquery. so your link should be <a class="tracker" href="your outgoing link here">thumbnail</a>

          <script>
          jQuery(document).ready(function(){
          jQuery("a.tracker").click(function(){
          url=jQuery(this).attr('href');
          jQuery(this).attr('href','/tp/out.php?p=100&link=click&url=' + escape(url));
          });
          });
          </script>
          ☆☆☆ WebDesign Rockstar ☆☆☆

          Comment

          Working...