/*
BidHopper v2.00 Sep. 09, 2005 for osCommerce Software (www.oscommerce.com)
v2.1 8/04/2006: Modified by Bruce H. Tsunami PC Productions (www.pc-productions.net) including:
- script no longer requires manual adjustments of site URL and product image URL.
- product query updated to pull only products with price greater than $0; to accomodate for the popular "call for
price" contribution.
*/
require('includes/application_top.php');
?>
BidHopper Dynalist Generator v2.0 for osCommerce Site
BidHopper Dynalist v2.0 for osCommerce
##############################################################################
###### ONLY CHANGE THE FOLLOWING (2) VARIABLES TO SET YOUR SITES PATHS: ######
##############################################################################
$mysiteurl = "http://".$_SERVER['HTTP_HOST'] . DIR_WS_CATALOG; // This is the FULL URL to your Sites Cart Location
$mysiteimgs = "http://".$_SERVER['HTTP_HOST'] . DIR_WS_CATALOG . DIR_WS_IMAGES; // This is FULL URL to your sites Cart IMAGES Location
##############################################################################
##### DO NOT CHANGE ANY THING ELSE BELOW THIS LINE FOR PROPER OPERATION! #####
##############################################################################
$productlist = mysql_query("SELECT * FROM products WHERE products_status=1
AND products.products_status != 0
AND products.products_price != 0
AND products.products_price != ''
ORDER BY products_id ASC");
if($productlist==TRUE) {
while ($products=mysql_fetch_array($productlist)) {
$bidhopper_url=$products['products_image'];
$bidhopper_id=$products['products_id'];
$bidhopper_price=$products['products_price'];
$bidhopper_image=$products['products_image'];
$item_type="classified";
echo "$item_type";
$bidhopper_url="$mysiteurl";
echo "$bidhopper_url"; echo "product_info.php?products_id=$bidhopper_id";
$productdetails = mysql_query("SELECT * FROM products_description WHERE language_id=1 AND products_id =
'".$bidhopper_id."'");
while ($details=mysql_fetch_array($productdetails)) {
$text = $details['products_name'];
$text = html_entity_decode(strip_tags($text));
$replacethis = "'";
$withthis = "'";
$text = str_replace($replacethis, $withthis, $text);
$pattern="[^a-zA-Z0-9\.'$&-]";
$replace=" ";
$text=ereg_replace($pattern,$replace,$text);
$text=preg_replace('/\s\s+/', ' ', $text);
$productname=trim($text);
echo "$productname";
$rest = substr("$bidhopper_price", 0, -2); // This removes the last two 0's from the price field in the DB
echo "$rest";
echo "Never";
echo "Self";
if($products['products_image']){
echo "$mysiteimgs"; echo "$bidhopper_image";
} else {
echo "http://www.bidhopper.com/images/noimage.jpg";
}
echo "
"; ?>
}}} ?>