Results 1 to 8 of 8
  1. #1
    Member
    Join Date
    January 18th, 2005
    Posts
    189
    Hello -

    I found a great perl script that will track outbound clicks automatically. For example, the URL : http://www.mysite.com/cgi-bin/clickt...www.google.com will send the user to google, and track a click to www.google.com

    Well, I tried the url : http://www.mysite.com/cgi-bin/clickt...le.com&afsrc=1 and the perl script tries to send the user to "www.google.com&afsrc=1"

    I know nothing about PERL, but I am looking at the script and can see where the query string is held in a variable. If I can only get some help to remove the &afsrc=1 in the script, I would REALLY appreciate it. Anyone willing to have a quick look?

    Thanks...

    Danski

  2. #2
    Member
    Join Date
    January 18th, 2005
    Posts
    189
    Hmmm...someone may be able to answer this without even getting the entire file...

    Here is the block of code that I think needs to be changed to remove the "&afsrc" :

    # Process the query string
    my @query = split(/=/, $ENV{'QUERY_STRING'});
    my $action = shift(@query);
    my $value = join('=', @query);

    I think it is in the variable @query...

    Thanks for any help...

    Danski

  3. #3
    Full Member c4's Avatar
    Join Date
    January 18th, 2005
    Posts
    488
    Well, you could just remove the "&afsrc=1" from the link, but you can also try by replacing that code you posted with this:

    # Process the query string
    my ($action,$value);
    @pairs = split(/&/, $ENV{'QUERY_STRING'});
    my $right = shift(@pairs);
    ($action,$value) = split(/=/, $right);

    or this:

    # Process the query string
    @pairs = split(/&/, $ENV{'QUERY_STRING'});
    my $right = shift(@pairs);
    my @query = split(/=/, $right);
    my $action = shift(@query);
    my $value = join('=', @query);

    Let me know if it worked



    YOURsoft affiliate software
    Join YOURsoft "affiliate program for affiliate software"!

  4. #4
    Member
    Join Date
    January 18th, 2005
    Posts
    189
    c4-

    I appreciate your help - got a compilation error when substituting either block of your code into the script. I sent you a PM with the full script, I really appreciate it.

    Thanks,

    Dan

  5. #5
    Full Member c4's Avatar
    Join Date
    January 18th, 2005
    Posts
    488
    Danski, you're not replying to my PM? Did it work now?



    YOURsoft affiliate software
    Join YOURsoft "affiliate program for affiliate software"!

  6. #6
    ABW Ambassador CrazyGuy's Avatar
    Join Date
    January 18th, 2005
    Posts
    1,463
    I don't know this script, but it seems to me you just need to change:

    http://www.mysite.com/cgi-bin/clickt...le.com&afsrc=1

    to:

    http://www.mysite.com/cgi-bin/clickt...www.google.com

    this keeps the (essential) afsrc=1 tag/value associated with the clicktracker script, and removes it from the value "http://www.google.com" given to the "dl" tag.


    --------------
    Are you Crazy?

  7. #7
    Member
    Join Date
    January 18th, 2005
    Posts
    189
    c4 -

    You da man...it worked - sorry I took a break this weekend and didn't get back to you quickly. Works like a charm...

    D

  8. #8
    Full Member c4's Avatar
    Join Date
    January 18th, 2005
    Posts
    488
    Hey don't excuse youreself for not replying earlier, just wanted to make sure it worked

    Cheers!



    YOURsoft affiliate software
    Join YOURsoft "affiliate program for affiliate software"!

  9. Newsletter Signup

+ Reply to Thread

Similar Threads

  1. Allposters Perl
    By reaper in forum Cusimano.com Scripts
    Replies: 5
    Last Post: May 31st, 2005, 12:51 AM
  2. need some perl code...
    By SBTC in forum Programming / Datafeeds / Tools
    Replies: 14
    Last Post: July 30th, 2003, 06:27 AM
  3. Cron/Perl
    By c4 in forum Programming / Datafeeds / Tools
    Replies: 9
    Last Post: February 4th, 2003, 01:44 PM
  4. Perl help.
    By mewmew in forum Programming / Datafeeds / Tools
    Replies: 2
    Last Post: October 10th, 2002, 03:41 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •