Membership is FREE, giving all registered users unlimited access to every Acorn Domains feature, resource, and tool! Optional membership upgrades unlock exclusive benefits like profile signatures with links, banner placements, appearances in the weekly newsletter, and much more - customized to your membership level!

What are people using for their affiliate datafeeds?

Status
Not open for further replies.
That would be good Nick.

I tried to make the jump from content units to data feeds in the past but always hit a brick wall.
 
Well I have a the description and a small thumbnail displayed for the products.

In the past I've submitted data to the database from html forms when the visitor hits a submit button.

Does the var_dump send the data to the database instead?
 
I've set up a database and table.

The table has three fields name, awThumb, buynow

I need some help formatting the mysql insert

I have this but it's incorrect.

mysql_query("INSERT INTO shop (name, awThumb, buynow)
VALUES ('$product->text->name;', '$product->uri->awThumb;', '$product->price->buynow;')");
 
I was the developer of the enhanced version of Affilistore - AffilistoreEnhanced or ASE. Affilistore is a dead product though I still use ASE for some uk sites e.g. watchtime, chronwatch.

A reworking of some of the enhanced features of ASE is my next project in line after I wrap up the latest v1 release of the iCodes WP plugin (icws).
 
Well I've made some good progress today, it's been really slow tho.

This is what I've managed

I've took the xml datafeed and selected chose three details name, thumbnail and price.

Set up a mysql database table to accept the three items

Inserted the three items

Displayed the contents of the database

All pretty basic stuff but it's a bit of a steep learning curve when you're just starting out.
 
Well I've made some good progress today, it's been really slow tho.

This is what I've managed

I've took the xml datafeed and selected chose three details name, thumbnail and price.

Set up a mysql database table to accept the three items

Inserted the three items

Displayed the contents of the database

All pretty basic stuff but it's a bit of a steep learning curve when you're just starting out.

You have the hart parts done :) Now just learn to sort the data and manipulate it and you are laughing!
 
This morning I've added a 'category' and 'affiliate link' fields to the database.

So now I have 6 pages, sorted by categories and a working affiliate links.

The pages aren't styled yet so it's very basic.

XML and datafeeds are new to me so I'm pretty chuffed to have got this far.

If anyone is interested in seeing what I've done as a beginner with xml and datafeeds please PM me for a link, but it is an adult store, so it's NSFW.
 
Congrats for getting so far from scratch good to hear people's development ideas. PM me the URL I'm always willing to take a look / offer some advice.
 
If anyone is following this here's the code I've got to populate the database from the XML i have downloaded from affiliate window.

Updated fully working code


You'll need dbconn.php which holds your username and password separate form the main php

dbconn.php looks like

PHP:
<?php
$username="####your database username####";
$password="###your database password####";
$database="philb_bdolls";
?>


The main code to submit the .xml data is here

This is a standard connect to database code.

PHP:
<?php
include('../shop/dbconn.php');

$con = mysql_connect(localhost,$username,$password);
if (!$con)
{
die('Could not connect: ' . mysql_error());
}

mysql_select_db("philb_bdolls", $con);


This section reads the .xml file 'datafeed_79329.xml'

Then converts the info from the feed into a string and inserts it into the database.

PHP:
$xml = simplexml_load_file("../shop/datafeed_79329.xml");

foreach($xml->merchant->prod as $product){ 

$name = $product->text->name;
$awThumb = $product->uri->awThumb;
$buynow = $product->price->buynow;
$mcat = $product->cat->mCat;
$awTrack = $product->uri->awTrack;
$descrip = $product->text->desc;

mysql_query("INSERT INTO shop (name, awThumb, buynow, mcat, awtrack, descrip)
VALUES ('$name', '$awThumb', '$buynow', '$mcat', '$awTrack', '$descrip')");
}


if (!mysql_query($sql,$con))
{
die('Error: ' . mysql_error());
}
echo "1 record added";

mysql_close($con)
?>
 
Last edited:
I'm pulling to products from the database with this.

I've update this code and it's now fully working.

Each category in the shop pulls products from the database depending on the category field.


PHP:
     <?php
include('../dbconn.php');

$con = mysql_connect(localhost,$username,$password);
if (!$con)
  {
  die('Could not connect: ' . mysql_error());
  }

mysql_select_db("philb_bdolls", $con);
//SELECT * FROM tablename WHERE field1-name='1'
$query="SELECT * FROM shop WHERE mcat='Bondage Kits' ORDER BY buynow ASC";
$result=mysql_query($query);
$nrows = mysql_num_rows($result);

echo "<table>";
for ($i=0;$i<$nrows;$i++)
{
	$n = $i + 1;
	$row = mysql_fetch_array($result);
	extract($row);
 ?>
 
  <table border="0" cellpadding="0" cellspacing="10">
  <tr>
    <td><a href="<?php echo $awtrack ?>"><img src="<?php echo $awThumb  ?>" width="80" /></a></td>
    <td width="400" valign="top" class="descrip"><a href="<?php echo $awtrack ?>"><?php echo $name  ?></a><br />
    <span class="descript"><?php echo $descrip; ?> <a href="<?php echo $awtrack ?>">...read more</a></span></td>
    <td width="100" valign="top">£ <?php echo $buynow;  ?></td>
  </tr>
  <?php
}
 ?>
 
Last edited:
Hello

The structure of the table is


CREATE TABLE `shop` (
`name` varchar(50) NOT NULL,
`awThumb` blob NOT NULL,
`buynow` decimal(10,2) NOT NULL,
`mcat` varchar(50) NOT NULL,
`awtrack` varchar(255) NOT NULL,
`descrip` varchar(120) NOT NULL,
KEY `name` (`name`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

I have updated the code above but didn't want to fill the 'Affiliate Marketing' forum with php code.

I'm happy that the code is working so I will start a new thread in the coding section on this topic
 
Like nick279, I have also created my own system to import feeds. I initially download from a feed and then update prices using their API. I also have the ability to import from multiple networks and map each networks schema to my db.

All my feed data in inserted into a central database that can then be used by multiple sites.

I have an admin interface to create a new site, add merchants to a site and also select key categories that the site will focus around. This will then rapidly build a site with all products that fall under such category. The admin tool also allows to create new categories, create features for products and also map products to brands.

As duplicate content is often mentioned with feed data, I have a little CMS that will create a new product name and description etc which will be used if a record exists against a product Id(My own product id). (The product table already has 150,000 products in :) ). A little touch i have added in is the ability to record users that are interested in changes to product prices, so when a change in price occurs, an email is sent out with details.

I'm currently finishing up my product filtering which I feel will be a massive bonus in the future.

The system has been a labour of love and pain for a while and I'm looking to release a big site this side of Christmas. I will post site url when live.
 
Well I've been working hard on this the last few days and it's almost finished.

I have some copy to add to the pages and a couple of coding ideas I'd like to implement.

Code wise:

I have a search box, I'd like to take the search terms people enter in the box and add them to a table in the database so I can collect what people are looking for and add those items to the main page.

Check it out Warning Adult toy site, NSFW
 
Status
Not open for further replies.

The Rule #1

Do not insult any other member. Be polite and do business. Thank you!

Members online

Premium Members

New Threads

Our Mods' Businesses

*the exceptional businesses of our esteemed moderators
General chit-chat
Help Users
  • No one is chatting at the moment.
      There are no messages in the current room.
      Top Bottom