There are multiple ways to utilize search for eBay auctions. One of the most popular ways is to utilize eBay's API to do look ups, then you would return the results and add flexible desination rover links to it. You can learn more by clicking this link for connecting to eBay's API for real time results.
Another option is to use eBay's editor kit, but this might not be ideal, since controllability is minimized with the editor kit. Let's say you wanted to create a your own HTML search forms that would take search criteria input and direct the user to the eBay's search result page? You can still maintain rover tracking with some simple javascript.
This solution will send the user to eBay's search result page. If you want to display the result on your page, you'll need to explore the API, or optionally the eBay RSS handling. Either case will involve serverside language (eg: PHP, ASP, etc). If you're looking for a simple HTML/JavaScript solution, then here is my example below:
<script language="javascript">
function doSearch(frm){
var pid = '1231323'; // your CJ PID
var aid = '5463217'; // flex destination tool
var catid = '50128'; // baseball penants
if(frm.SearchCriteria.value.length > 0){
var criteria = frm.SearchCriteria.value;
var url = 'http://rover.ebay.com/rover/1/711-1751-2978-71/1?AID=' + aid + '&PID='+ pid + '&mpre=http%3A%2F%2Fsearch.ebay.com%2Fsearch%2Fsearch.dll%3Fsofocus%3Dbs%26sbrftog%3D1%26catref%3DC6%26from%3DR10%26satitle%3D' + criteria + '%26sacat%3D' + catid + '%2526catref%253DC6%26sargn%3D-1%2526saslc%253D2%26sadis%3D200%26sabfmts%3D1%26saobfmts%3Dinsif%26ftrt%3D1%26ftrv%3D1%26saprclo%3D%26saprchi%3D%26fsop%3D2%2526fsoo%253D2%26coaction%3Dcompare%26copagenum%3D1%26coentrypage%3Dsearch';
window.open(url,'auction','');
}else{
alert("Search criteria is required");
frm.SearchCriteria.focus();
return false;
}
}
</script>
<form action="#" name="SearchForm" onSubmit="return doSearch(SearchForm);" method="post">
Search:<input type="text" name="SearchCriteria" value=""> <input type="submit" value="Search">
</form>
What this code does is create a simple form that expects search criteria input. Once the user submits the form, the doSearch() function is called. In that function we are storing local aid, pid and catid variables that we use to assemble our flexible destination link. Finally, after the link is built, we execute the window.open() method to open the results in a new window.
For those of you unfamiliar with rover code. Rover is the server used for affiliate tracking.
Go Back
