Results 1 to 3 of 3

Thread: Create Redirect URL that include SugarCRM variables?

  1. #1
    mtg82814 is offline Junior Member
    Join Date
    Aug 2007
    Posts
    4

    Question Create Redirect URL that include SugarCRM variables?

    In an email campaign, Is it possible to have a Redirect URL include some arguments from SugarCRM.

    For example, I would like to have a redirect URL go to a different web server, but I want the redirect URL to include the SugarCRM ID of the user who clicked on the link in their email. This would be the equivilent of embeding the "$contact_id" variable in the redirect link.

    For example, i want the redirect url to be able to recieve the $contact_id. that way this server can then query the sugarcrm server to pull attributes based on the userid (contact_id).

    Is this possible?

    Thanks,

    -M

  2. #2
    mtg82814 is offline Junior Member
    Join Date
    Aug 2007
    Posts
    4

    Default Re: Create Redirect URL that include SugarCRM variables?

    I figured it out, for those who may be wondering I updated the file campaign_trackerv2.php:

    .
    .
    .
    $redirect_URL = $row['tracker_url'];
    sugar_cleanup();

    //--------------------------------------
    //foreach($_SERVER as $key=>$value) print $key . " = " . $value . "<br>";

    $identifier = $_REQUEST['identifier'];
    $identifier = $db->quote($identifier);

    $query2 = "SELECT target_id FROM campaign_log WHERE related_id='$track' AND target_tracker_key='$identifier'";
    $res2 = $db->query($query2);
    $row2 = $db->fetchByAssoc($res2);
    $contactID = $row2['target_id'];

    //print $query2 . "<br>";
    header("Location: $redirect_URL?sugarid=$contactID");
    //header("Location: $redirect_URL");
    //----------------end updates --------------------
    }
    else
    .
    .
    .


    I don't know if it works 100% yet, but its a start.

  3. #3
    yhercouet is offline Sugar Community Member
    Join Date
    Nov 2009
    Location
    Shanghai China
    Posts
    33

    Default Re: Create Redirect URL that include SugarCRM variables?

    Hello,


    You can check out our new module, it does what you explain in this topic:

    Smart Tracker

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 5
    Last Post: 2007-11-13, 02:51 PM
  2. Replies: 61
    Last Post: 2006-10-22, 08:40 AM
  3. Tracker Redirect URL - I don't understand
    By Debbie in forum General Discussion
    Replies: 6
    Last Post: 2006-01-20, 04:22 AM
  4. Replies: 0
    Last Post: 2006-01-06, 07:28 PM

Bookmarks

Posting Permissions

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