Announcement

Collapse
No announcement yet.

Affiliate searching my site - no longer works

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Affiliate searching my site - no longer works

    Hello,

    I have an affiliate programme, and one of my affiliates has a site which includes a price comparison facility. In version 7, the following code was used on his site to find the "searched for" product on my site, and details of the product were displayed. The affiliate site is www.bestwalks.com if it makes it easier to see it in action.

    Code used:

    <?php
    // Guidepost
    if(!empty($results_gp)) {
    preg_match("/\<actinicrices prod_ref=\"$gp_code\"(.*?)\<\/span\>/i", $results_gp, $price_str_gp);
    preg_match("/&#163;(.*?)&#46;([0-9]*)/", $price_str_gp[1], $price_gp);

    $url = $gp_aff_address . "&shop/acatalog/" . $gp_url . '#a' . $gp_code;
    $availability = '<a href="' . $url . '" target="_blank">' . $gp_availability . '</a>';
    $book_price = "&pound;$price_gp[1]&#46;$price_gp[2]";
    $delivery_price = "&pound;" . $gp_delivery;
    $total_price = '<a href="' . $url . '" target="_blank">&pound;' . format_price($price_gp[1] + $price_gp[2]/100 + $gp_delivery) . '</a>';
    }
    else {
    $url = $gp_aff_address;
    $availability = "Not Available";
    $book_price = "-";
    $delivery_price = "-";
    $total_price = "-";
    }
    ?>
    <tr>
    <td><a href="<?= $url; ?>" target="_blank"><img src="http://bestwalks.com/script_images/gplogo.gif" width="134" height="78" border="0" alt="Buy from guidepost.uk.com"></a>
    <br /><?= $gp_description; ?></td>
    <td><?= $availability; ?></a></td>
    <td><?= $book_price; ?></td>
    <td><?= $delivery_price; ?></td>
    <td><?= $total_price; ?></a></td>


    This worked perfectly in V7, but since I have switched to V8, it no longer works. The affiliate links themselves work fine, it is just this search that is not working as it used to.

    Any ideas??
    www.guidepost.uk.com

    #2
    Hi,

    I'm not sure if I can help much here as I don't know php or your affiliate but on this line:

    preg_match("/\<actinicrices prod_ref=\"$gp_code\"(.*?)\<\/span\>/i", $results_gp, $price_str_gp);
    I can't see that '<actinicrices' is closed off anywhere. I don't know if that has anything to do with it?
    ********************
    Tracey
    SellerDeck

    Comment

    Working...
    X