xml-view"; $arr_file = file($url); $Parse_e1 = "<(.+)>"; $Parse_e2 = "<(.+)/>"; $result = join("",$arr_file); $result = ereg_replace("","-SSS-",$result); $result = ereg_replace("<","-VVV-",$result); $result = ereg_replace("-SSS-",">",$result); $result = ereg_replace("-TTT-","
</",$result); $result = ereg_replace("-VVV-","
<",$result); echo $result; #for ($i=0; $i < count($arr_file); $i++) #{ #print $arr_file[$i]."
"; #} exit; } $font_face_1 = ""; $file_mode = "books"; $file_node = "1"; #print $review."ssssssss"; $count = 0; ###############################change to gggg.com because category.org is too slow; note that prine_next_list has also changed $search_cgi_name = "$SCRIPT_NAME"; #print "$SCRIPT_NAME mmmmmmmmmm"; #$search_cgi_name = "http://www.gggg.com".$SCRIPT_NAME; $search_cgi_name = "/search.php"; #print "fffffffffffffffffffffffffffffff $SCRIPT_NAME"; $locale = "us"; $starters_us = array ("books|Books|1000|books", "photo|Photo|502394|photo", "wireless-phones|Wireless|301185|wireless", "pc-hardware|PCHardware|541966|pc", "videogames|VideoGames|468642|games", "dvd|DVD|130|video", "electronics|Electronics|172282|electronics", "kitchen|Kitchen|284507|kitchen", "magazines|Magazines|599872|magzines", "music|Music|301668|music", "classical|Classical|85|music|", "garden|OutdoorLiving|286168|garden|Garden", "software|Software|491286|software", "universal|Tools|228013|tools", "toys|Toys|171280|toys", "video|VHS|404272|video", "apparel|Apparel|1036592|apparel|0|", "jewelry|Jewelry|3367581|jewelry|0|", "musicalinstruments|MusicalInstruments|11091801|musicalinstruments|0|", "health|HealthPersonalCare|3760901|health|0|", "beauty|Beauty|3760911|beauty|0|", "sports|SportingGoods|3375251|sports|0|", "office|OfficeProducts|1064954|office|0|"); #"asin|asin|0|asin|0|", #"asinxml|asinxml|0|asinxml|0|"); #print "$search_cgi_name ttttttttt"; #print $image_size."aaaaa"; #$search = "algebra"; if ($review == "" and $total_page == "") { $review = "on"; } if ($page_count == "") { $page_count = 1; } if ($total_page == "") { $total_page = 1; } if ($image_size == "") { $image_size = "medium"; #$image_size = "small"; } if ($max_item == "") { $max_item = 0; } if ($sort == "") { $sort = "pmrank"; } if ($simple_list) { $type = "lite"; } if ($searchtype == "") { $searchtype = "Keywords"; } #print $photo_asin; $search_d = rawurldecode($search); #print "$search and $search_d = 1\n"; #$search = format($search_d); #$search = rawurlencode($search); $sort = urlencode($sort); #print "sort = $sort\n"; $total_page_n = $page_count * $total_page; $total_page_p = ($page_count - 1) * $total_page; $productname = rawurldecode($productname); $nn_node = $node; if ($locale == "us") { $starters = $starters_us; } if ($locale == "uk") { $starters = $starters_uk; } if ($locale == "de") { $starters = $starters_de; } if ($mode == "") { $mode = "books"; } $count_line = count($starters); for($x_au=0;$x_au<$count_line;$x_au++) { $search_line =split("\|", $starters[$x_au]); #print "\n nnnn $node \n"; if ($mode == $search_line[0]) { $subject = $search_line[1]; if (!$node) { $node =$search_line[2]; } #$search_mode = $search_line[3]; $next_node = $search_line[4]; #print "
ddddddddddddddd $next_node"; if ($next_node != "0") { $next_node = $node; } } } if ($nn_node) { $node = $nn_node; $next_node = $nn_node; } #$search = ereg_replace(" "," ",$search); #$search = ereg_replace(" "," ",$search); #$search = ereg_replace(" ","%20",$search); #type = "complete" for header"; #$browse_subject = "Browse: $subject (Main Menu)"; html_head($mode, $search_d, $page, $image_size, $review, $total_page, $subject, $search_cgi_name, $simple_list, $photo_asin, $searchtype, $productname, $node_name); #if($simple_list || $total_page > 1 || !$review || $image_size != "medium") #{ #$advanced = "advanced"; #} #else #{ #$advanced = ""; #} print_form("", $mode, $search_d, $page, $image_size, $review, $total_page, $subject, $search_cgi_name, $simple_list, $sort, $searchtype); #print "$total_item && $page_count != 1"; #print " mode = $file_mode, search = $search; page = $page\n"; #print "$total_page_p - $total_page_n sssssssss\n"; #print $page."aaaaa\n"; #$TotalResults = 0; if ($nn_node) { #$file_next_old = "/www/browse/$mode/$node/next.txt"; #comment out 4/24/2004 $file_next_old = "/us_1/csv/next/$mode/$next_node"; } else { #$file_next_old = "/www/browse/$mode/next.txt"; $file_next_old = "/us_1/csv/next/$mode/$next_node"; } #print "
aaaaaaaaaaaaaa $file_next_old"; $file_url_dir = "http://www.category.org/browse/$mode/"; $page = $total_page_p; if ($page_count < 2) { print_next_list($file_next_old, $file_url_dir, $mode); } if($total_item && $page_count != 1) { write_page_line($page_count, $mode, $search, $image_size, $review, $total_page, $total_item, $search_cgi_name, $simple_list, $sort, $node, $node_name); #print "$font_face_1 Click image to see lager photo

"; #print "
page and page_count = $page_count
"; } #print "$page_count == 1 and $mode"; while ($total_page_p <= $page && $page < $total_page_n) { $page++; #print " stage =$search_step: $file_mode, $file_node; search nodes: page = $page\n"; #if ($page == 1) change for search review 10/20/2004 if (!$total_item) { $total_item = Main_Search($page_count, $mode, $search, $page, $image_size, $review, $total_page, $simple_list, $search_cgi_name, $photo_asin, $node, $sort, $searchtype, $node_name, $subject, $public_key, $private_key); } else { Main_Search($page_count, $mode, $search, $page, $image_size, $review, $total_page, $simple_list, $search_cgi_name, $photo_asin, $node, $sort, $searchtype, $node_name, $subject, $public_key, $private_key); } #Main_Search($file_mode, $file_node, $page); } $contact = '

contact: info@n2000.com'; $copyright = '

Copyright © 1998-2007 geometry.net'; if ($total_item == 0 and $searchtype != "asin" and $searchtype != "ListManiaSearch" and $mode != "review") { #print "aaa $mode"; if ($search && $mode !="office-products") { Print "Your search - $subject : $search_d - did not match any items.
You may try a new search, or browse the subcategories for $subject:

"; $search = ""; print $browse_subject; print_next_list($file_next_old, $file_url_dir, $mode); Main_Search($page_count, $mode, $search, $page, $image_size, $review, $total_page, $simple_list, $search_cgi_name, $photo_asin, $node, $sort, $searchtype, $node_name, $subject, $public_key, $private_key); } elseif ($search) { Print "Your search - $subject : $search_d - did not match any items.

"; } } if ($total_item) { write_page_line($page_count, $mode, $search, $image_size, $review, $total_page, $total_item, $search_cgi_name, $simple_list, $sort, $node, $node_name); } #print_form("advanced", $mode, $search_d, $page, $image_size, $review, $total_page, $subject, $search_cgi_name, $simple_list, $sort, $searchtype); #if($page_count == 1 and $mode) if($mode && $search && $mode !="office-products") { #print $browse_subject; print_next_list($file_next_old, $file_url_dir, $mode); #print "$file_next_old, $file_url_dir"; } if ($total_item) { print "

Questions on ordering or shipping? click here for help."; } #if ($mode != "office-products") #{ print $copyright; print $contact; #} print ""; print '

hit counter
'; print ""; ?> "; $font_face_1 = ""; $font_face_2 = ""; #print "$font_face_1 --ddddddddd--"; #print $ff_mode; $count = 0; $stop = 0; $file_desc_dir = "/www/desc/$ff_mode/"; #$type = "lite"; if ($simple_list == "on") { $type = "lite"; } else { $type = "heavy"; } #$sort = "+daterank"; #$sort = ""; $Parse_Details = "#(.*?)#"; #note that this is for preg_match_all so has to add delimiter # or / # (3/9/2003) note for new php here for preg_mathc_all we need .*?, while for preg_match we only need .+ -----------------very important $Parse_TotalResults = "(.+)"; $Parse_Asin = "(.+)"; $Parse_Asin_1 = "(.+)"; $Parse_ItemAttributes = "(.+)"; $Parse_FormattedPrice = "(.+)"; $Parse_OfferSummary = "(.+)"; $Parse_LowestNewPrice = "(.+)"; $Parse_LowestUsedPrice = "(.+)"; $Parse_TotalNew = "(.+)"; $Parse_TotalUsed = "(.+)"; #http://ec1.images-amazon.com/images/I/21D3YMYYKDL.jpg #http://ecx.images-amazon.com/images/I/217WX653EAL.jpg140119 $Parse_OurPrice = "(.+)"; #$Parse_ImageUrlSmall = "http://images.amazon.com/images/P/(.+)"; #$Parse_ImageUrlMedium = "http://images.amazon.com/images/P/(.+)"; # http://ecx.images-amazon.com/images/I/515EFSe642L._SL500_.jpg #$Parse_ImageUrlSmall = "http://ecx.images-amazon.com/images/I/[A-Za-z_0-9]{1,11}\.jpg"; #$Parse_ImageUrlMedium = "http://ecx.images-amazon.com/images/I/[A-Za-z_0-9]{1,11}\._[A-Za-z_0-9]{1,5}_\.jpg"; #$Parse_ImageUrlMedium = "http://ecx.images-amazon.com/images/I/(.+)\.jpg"; #$Parse_ImageUrlLarge = "http://ecx.images-amazon.com/images/I/[A-Za-z_0-9]{1,11}\.jpg"; $Parse_ImageUrlSmall = "http://ecx.images-amazon.com/images/I/[A-Za-z_0-9]{1,11}\._[A-Za-z_0-9]{1,5}_\.jpg"; $Parse_ImageUrlMedium = "http://ecx.images-amazon.com/images/I/[A-Za-z_0-9]{1,11}\._[A-Za-z_0-9]{1,5}_\.jpg"; $Parse_ImageUrlLarge = "http://ecx.images-amazon.com/images/I/[A-Za-z_0-9]{1,11}\._[A-Za-z_0-9]{1,5}_\.jpg"; #$Parse_ImageUrlLarge = "http://images.amazon.com/images/P/(.+)"; $Parse_Media = "(.+)"; $Parse_ReleaseDate = "(.+)"; $Parse_Manufacturer = "(.+)"; $Parse_ProductDescription = "#(.*?)#"; $Parse_Price = "(.+)"; $Parse_CustomerReviews = "(.+)"; #for pre_macth $Parse_Review = "#(.*?)#"; $Parse_Catalog = "(.+)"; $Parse_ProductName = "(.+)"; $Parse_AvgCustomerRating = "(.+)"; $Parse_TotalCustomerReviews = "(.+)"; $Parse_Summary = "(.+)"; $Parse_Comment = "(.+)"; $Parse_Rating = "(.+)"; $Parse_Feature = "#(.*?)#"; $Parse_ProductGroup = "(.+)"; $Parse_Brand = "(.+)"; $Parse_Department = "(.+)"; $Parse_Source = "(.+)"; $Parse_Content = "(.+)"; $Parse_SimilarProducts = "(.+)"; $Parse_SimilarProduct = "#(.*?)#"; $Parse_ListmaniaLists = "(.+)"; $Parse_ListmaniaList = "#(.*?)#"; $Parse_ListId = "(.+)"; $Parse_ListName = "(.+)"; $Parse_BrowseNodes = "(.+)"; $Parse_BrowseNode = "#(.*?)#"; $Parse_ListId = "(.+)"; $Parse_ListName = "(.+)"; $Parse_ListPrice = "(.+)"; $Parse_BrowseList = "(.+)"; $Parse_Isbn = "(.+)"; $Parse_Availability = "(.+)"; $Parse_SalesRank= "(.+)"; $Parse_NumMedia = "(.+)"; $Parse_SimilarProducts = "(.+)"; #$Parse_Author = "<$Author_name>(.+)"; $Parse_BrowseName = "(.+)"; $Parse_BrowseNode = "#(.*?)#"; $Parse_Product = "#(.*?)#"; $Parse_Features = "(.+)"; $Parse_Directors = "(.+)"; $Parse_Director = "#(.*?)#"; ################################################################################ ################################################## ########################################################################### ######################################################################## $with_pic = 1; $with_star = 1; $num_rec = 20; $book_num_rec = 5; $cut_text_length = 300; ########################################################################### $local_image_base = "http://www.algebraic.net/subject_image/"; $use_local_image = 0; # use www.8r.com's image $local_url = "http://www.geometry.net/"; #$star_url = "http://www.algebraic.net/"; $star_url = "http://g-images.amazon.com/images/G/01/detail/"; $search_engine = "http://www.geometry.net/cgi-bin/988.cgi"; ############################################################################# ########################################################################### $geometry_logo = 'geometry.net'; $main_logo = ''; $logo = 'j4.com'; $contact = '
contact: support@geometry.net
'; $copyright = '
Copyright © 1998-2002 geometry.net
'; ############################################################################# $add_line_main = "http://www.amazon.com/exec/obidos/ASIN/"; $add_line_de = "http://www.amazon.de/exec/obidos/ASIN/"; $add_line_fr = "http://www.amazon.fr/exec/obidos/ASIN/"; $add_line_ca = "http://www.amazon.ca/exec/obidos/ASIN/"; $add_line_uk = "http://www.amazon.co.uk/exec/obidos/ASIN/"; $add_line_jp = "http://www.amazon.co.jp/exec/obidos/ASIN/"; #$add_line_back = "/categoricalgeome"; #$add_line_back_de = "/geometrynet01-21"; #$add_line_back_fr = "/geometrynet0c-21"; #$add_line_back_ca = "/geometrynet-20"; #$add_line_back_uk = "/geometrynet-21"; $add_line_back = "/gemotrack4-20/ref=nosim"; $add_line_back_de = "/geometrynet01-21/ref=nosim"; $add_line_back_fr = "/geometrynet0c-21/ref=nosim"; $add_line_back_ca = "/geometrynet-20/ref=nosim"; $add_line_back_uk = "/geometrynet-21/ref=nosim"; $add_line_back_jp = "/geometrynet-22/ref=nosim"; ### $single_author = 0; $by_name = "by"; if ($ff_mode == "books") { $Authors_name = "Authors"; $Author_name = "Author"; #print $Author_name." $ff_mode ---------------\n
"; $author_search = "Author"; } elseif ($ff_mode == "classical" or $ff_mode == "music") { $Authors_name = "Artists"; $Author_name = "Artist"; $by_name = "Artist:"; $author_search = "Artist"; } elseif ($ff_mode == "dvd" or $ff_mode == "vhs" or $ff_mode == "video" ) { $Authors_name = "Starring"; $Author_name = "Actor"; $by_name = "Starring:"; $author_search = "Actor"; } else { $Authors_name = "Manufacturer"; $single_author = 1; $Author_name = "Manufacturer"; $by_name = "Manufacturer"; $author_search = "Manufacturer"; } #print $Author_name." $ff_mode ---------------\n
"; $Parse_Authors = "<$Authors_name>(.+)"; $Parse_Author = "#<$Author_name>(.*?)#"; $Parse_Author_simple = "<$Author_name>(.+)"; #print "final = <$Author_name>(.+) $Parse_Author
"; $search_qqq = $search; #$url = "http://xml.amazon.com/onca/xml2?t=webservices-20&dev-t=D2NIHDVG1L9MTA&BrowseNodeSearch=$ff_node&mode=$ff_mode&type=$type&page=$page&sort=$sort&f=xml"; if (!$search and $node) { $searchtype = "BrowseNode"; $search_qqq = $node; #$url = "http://xml.amazon.com/onca/xml2?t=webservices-20&dev-t=D2NIHDVG1L9MTA&AsinSearch=$photo_asin&type=$type&f=xml"; #$url = "http://xml.amazon.com/onca/xml2?t=webservices-20&dev-t=D2NIHDVG1L9MTA&BrowseNodeSearch=$node&mode=$ff_mode&type=$type&page=$page&sort=$sort&f=xml"; #print $url."\n"; } elseif($search and $simple_list) { #$url = "http://xml.amazon.com/onca/xml2?t=webservices-20&dev-t=D2NIHDVG1L9MTA&KeywordSearch=$search&mode=$ff_mode&type=lite&page=$page&sort=$sort&f=xml"; #print $url; } #$url = "http://xml.amazon.com/onca/xml3?t=webservices-20&dev-t=D2NIHDVG1L9MTA&$searchtype=$search_qqq&mode=$ff_mode&type=$type&page=$page&sort=$sort&f=xml"; #$ff_mode = "$subject"; if ($searchtype == "BrowseNodeLookup") { $url = "http://webservices.amazon.com/onca/xml?Service=AWSECommerceService&SubscriptionId=15RJV3GX2B2Y33Y9BMR2&Operation=BrowseNodeLookup&BrowseNodeId=$search_qqq&ItemPage=$page&ResponseGroup=BrowseNodes "; } elseif ($ff_mode == "review") { $url = "http://webservices.amazon.com/onca/xml?Service=AWSECommerceService&SubscriptionId=15RJV3GX2B2Y33Y9BMR2&Operation=ItemLookup&ItemId=$search_qqq&ReviewPage=$page&ResponseGroup=Large,EditorialReview,Reviews"; } elseif ($searchtype == "asin" or $ff_mode == "asin" or $searchtype == "asinxml" or $ff_mode == "asinxml") { $url = "http://webservices.amazon.com/onca/xml?Service=AWSECommerceService&SubscriptionId=15RJV3GX2B2Y33Y9BMR2&Operation=ItemLookup&ItemId=$search_qqq&ReviewPage=$page&ResponseGroup=Large"; $arr_file = aws_signed_request("com", array("Operation"=>"ItemLookup","ResponseGroup"=>"Large","ItemId"=>"$search_qqq","ItemPage"=>"$page","AssociateTag"=>"$PartnerId"), $public_key, $private_key); } elseif ($searchtype == "list") { $url = "http://webservices.amazon.com/onca/xml?Service=AWSECommerceService&SubscriptionId=15RJV3GX2B2Y33Y9BMR2&Operation=ListLookup&ListId=$search_qqq&ListType=Listmania&ReviewPage=$page&ResponseGroup=Large"; } else { $url = "http://ecs.amazonaws.com/onca/xml?Service=AWSECommerceService&SubscriptionId=15RJV3GX2B2Y33Y9BMR2&Operation=ItemSearch&$searchtype=$search_qqq&SearchIndex=$subject&ItemPage=$page&ResponseGroup=Large"; # print $url."
$searchtype + $ff_mode "; $arr_file = aws_signed_request("com", array("Operation"=>"ItemSearch","$searchtype"=>"$search_qqq","ResponseGroup"=>"Large","SearchIndex"=>"$subject","ItemPage"=>"$page","AssociateTag"=>"categoricalgeome"), $public_key, $private_key); #$arr_file = aws_signed_request("com", array("Operation"=>"ItemSearch","Keywords"=>"algebra","ResponseGroup"=>"Large","SearchIndex"=>"Books","ItemPage"=>"page","AssociateTag"=>"$PartnerId"), $public_key, $private_key); } $base_file = "$search_cgi_name"; #$base_url_simple = "Simple List\n"; #$url = "http://www.yahoo.com/index.html"; # print $url."
$searchtype + $ff_mode 11111111111111111111111111 pub = $public_key, private = $private_key"; #$arr_file = file($url); #$arr_file = aws_signed_request("com", array("Operation"=>"ItemSearch","Keywords"=>"algebra","ResponseGroup"=>"Large","SearchIndex"=>"Books","ItemPage"=>"1","AssociateTag"=>"$PartnerId"), $public_key, $private_key); $result = join("",$arr_file); #print "aaaaaaaaaaaaaaaaaaaaaa $arr_file aaaaaaaaaaaaaaaa"; $result = $arr_file; #print "".$result."
"; if ($searchtype == "asinxml" or $ff_mode == "asinxml") { print $result; $stop = 1; exit; } elseif (eregi("There are no exact matches for the search", $result)) { $stop = 1; } elseif (strlen($result) < 100) { print "
The server is probably busy or down! Please reload again!"; } $result = ereg_replace("\n","",$result); ############################### delete #print "\n\n\n $result \n\n\n"; #$reg = "/(.*?)<\/a><\/b>
(.*?)<\/font>/i"; if (eregi($Parse_TotalResults, $result, $mat) && $page ==1) { $TotalResults = strip_tags($mat[0]); #print "
aaaaaaaaaaaaaa $TotalResults
"; } if (eregi($Parse_ListName, $result, $mat) && $page ==1 && $searchtype == "ListManiaSearch") { $ListName = strip_tags($mat[0]); print "
$ListName

"; } if($TotalResults > 0 && $page == 1) { #print "
page = $page page_count = $page_count
"; write_page_line($page_count, $ff_mode, $search, $image_size, $review,$total_page, $TotalResults, $search_cgi_name, $simple_list, $sort, $node, $node_name); #print "$font_face_1 Click image to see lager photo

"; } preg_match_all($Parse_Details, $result, $matches); $num = count($matches[0]); #$lnumber = ($page_count - 1)*($total_page*10) + 1; $lnumber = ($page - 1)*10 + 1; #$html_small = "\n "; $html_small = ""; #
    "; $html_med = ""; $html_medium = ""; $html_large = ""; $im_exist = 0; if ($num%2 == 0) { $num_half = $num/2 - 1; } else { $num_half = ($num - 1)/2; } $im_total = ""; $im_medium_total = ""; $im_large_total = ""; for($x=0;$x<$num;$x++) { $item_count = $lnumber + $x; $item_line = $matches[0][$x]; #print "$count $item_line\n\n"; if ($item_line != "") { $count++; #print "$count\n"; $Asin = ""; $Catalog = ""; $Authors = ""; $Authors_1 = ""; $ProductName = ""; $ReleaseDate = ""; $Manufacturer = ""; $ImageUrlSmall = ""; $ImageUrlMedium = ""; $ImageUrlLarge = ""; $ListPrice = ""; $OurPrice = ""; $ListPrice_simple = ""; $OurPrice_simple = ""; $BrowseList = ""; $BrowseList_1 = ""; $Media = ""; $Isbn = ""; $ProductDescription = ""; $Availability = ""; $SalesRank = ""; $NumMedia = ""; $Reviews = ""; $Reviews_1 = ""; $AvgCustomerRating = ""; $TotalCustomerReviews = ""; $SimilarProducts = ""; $SimilarProducts_1 = ""; $Product = ""; $Author = ""; $Authors_1 = ""; $BrowseName = ""; #print "$count $item_line \n"; $ListPrice_name = ""; $OurPrice_name = ""; $discount_name = ""; $discount_simple = ""; $discount_only = ""; $discount = ""; $Features = ""; $Features_1 = ""; $Feature = ""; $Directors = ""; $Director = ""; $Lists_1 = ""; $Lists = ""; $LowestNewPrice = ""; $LowestUsedPrice = ""; $TotalNew = ""; $TotalUsed = ""; #print $item_line; if (eregi($Parse_Asin, $item_line, $mat)) { $Asin = strip_tags($mat[0]); } $ListPrice_tiny = ""; $ListPrice = ""; if (eregi($Parse_ItemAttributes, $item_line, $mat)) { $ItemAttributes = $mat[0]; if (eregi($Parse_ProductName, $ItemAttributes, $mat)) { $ProductName = strip_tags($mat[0]); #$ProductName = rawurldecode($ProductName); #$ProductName = ereg_replace ("%([a-fA-F0-9]{2,2})", chr(hex($1)), $ProductName); $ProductName_simple = ereg_replace("\(.+\)", "", $ProductName); $ProductName_simple = ereg_replace(":.+", "", $ProductName_simple); $array_pro = split(" ", $ProductName_simple, 10); $ProductName_short_simple = ""; $productName_q = rawurlencode($ProductName); for($tt=0;$tt<9;$tt++) { if (strlen($ProductName_short_simple) < 20 && $array_pro[$tt]) { $ProductName_short_simple .= $array_pro[$tt]." "; } } } if (eregi($Parse_FormattedPrice, $ItemAttributes, $mat)) { $ListPrice = strip_tags($mat[0]); $ListPrice_simple = ereg_replace("\\$", "", $ListPrice); $ListPrice_simple = ereg_replace(",", "", $ListPrice_simple); $ListPrice_name = "List Price:"; $ListPrice_tiny = "$ListPrice"; } $Authors_1 = ""; if (preg_match_all($Parse_Author, $ItemAttributes, $mat_auth)) { $num_auth = count($mat_auth[0]); #print "$num_auth bbbbbbbb \n"; for($x_au=0;$x_au<$num_auth;$x_au++) { $Author= strip_tags($mat_auth[0][$x_au]); $author_q = rawurlencode($Author); $Author= "$Author"; $Authors_1 = $Authors_1.$Author.""; #print "author_1 $Authors_1 \n
    "; } $author_simple = strip_tags($mat_auth[0][0]); if ($single_author) { $Authors = strip_tags($Authors); $author_q = rawurlencode($Authors); $Authors= "$Authors"; $Authors_1 = $Authors; } } if (eregi($Parse_ProductGroup, $item_line, $mat)) { $ProductGroup = strip_tags($mat[0]); } if (eregi($Parse_Authors, $ItemAttributes, $mat)) { $Authors = $mat[0]; #print "author -- $Authors \n"; $Authors_1 = ""; #print "$Parse_Author aaaaaaaaaaaaaaa-author\n"; preg_match_all($Parse_Author, $Authors, $mat_auth); $num_auth = count($mat_auth[0]); #print "$num_auth bbbbbbbb \n"; for($x_au=0;$x_au<$num_auth;$x_au++) { $Author= strip_tags($mat_auth[0][$x_au]); $author_q = rawurlencode($Author); $Author= "$Author"; $Authors_1 = $Authors_1.$Author.""; #print "author_1 $Authors_1 \n
    "; } $author_simple = strip_tags($mat_auth[0][0]); if ($single_author) { $Authors = strip_tags($Authors); $author_q = rawurlencode($Authors); $Authors= "$Authors"; $Authors_1 = $Authors; } } if (eregi($Parse_Directors, $ItemAttributes, $mat)) { $Directors = $mat[0]; $Directors_1 = ""; preg_match_all($Parse_Director, $Directors, $mat_auth); $num_auth = count($mat_auth[0]); for($x_au=0;$x_au<$num_auth;$x_au++) { $Director = strip_tags($mat_auth[0][$x_au]); $director_q = rawurlencode($Director); $Director = "$Director"; $Directors_1 = $Directors_1.$Director.""; } } if (eregi($Parse_ReleaseDate, $ItemAttributes, $mat)) { $ReleaseDate = strip_tags($mat[0]); } if (eregi($Parse_Manufacturer, $ItemAttributes, $mat)) { $Manufacturer = strip_tags($mat[0]); } if (eregi($Parse_Brand, $ItemAttributes, $mat)) { $Brand = strip_tags($mat[0]); } if (eregi($Parse_Department, $ItemAttributes, $mat)) { $Department = strip_tags($mat[0]); } $Features_1 = ""; preg_match_all($Parse_Feature, $ItemAttributes, $mat_auth); $num_auth = count($mat_auth[0]); for($x_au=0;$x_au<$num_auth;$x_au++) { $Feature= strip_tags($mat_auth[0][$x_au]); $Features_1 = $Features_1.$Feature.""; } } if (eregi($Parse_ImageUrlSmall, $item_line, $mat)) { $ImageUrlSmall = strip_tags($mat[0]); } if (eregi($Parse_ImageUrlMedium, $item_line, $mat)) { $ImageUrlMedium = strip_tags($mat[0]); # print "
    $ImageUrlMedium
    "; } if (eregi($Parse_ImageUrlLarge, $item_line, $mat)) { $ImageUrlLarge = strip_tags($mat[0]); #print $ImageUrlLarge; } if(!$ImageUrlSmall) { $ImageUrlSmall = "http://g-images.amazon.com/images/G/01/x-site/icons/no-img-lg.gif"; } if(!$ImageUrlMedium) { $ImageUrlMedium = "http://g-images.amazon.com/images/G/01/x-site/icons/no-img-lg.gif"; } if(!$ImageUrlLarge) { $ImageUrlLarge = "http://g-images.amazon.com/images/G/01/x-site/icons/no-img-lg.gif"; } $LowestNewPrice_tiny = ""; $LowestNewPrice = ""; if (eregi($Parse_OfferSummary, $item_line, $mat)) { $OfferSummary = $mat[0]; if (eregi($Parse_LowestNewPrice, $OfferSummary, $mat)) { $LPrice = $mat[0]; if (eregi($Parse_FormattedPrice, $LPrice, $mat)) { $LowestNewPrice = strip_tags($mat[0]); $LowestNewPrice_tiny = "$LowestNewPrice"; } } if (eregi($Parse_LowestUsedPrice, $OfferSummary, $mat)) { $LPrice = $mat[0]; if (eregi($Parse_FormattedPrice, $LPrice, $mat)) { $LowestUsedPrice = strip_tags($mat[0]); } } if (eregi($Parse_TotalNew, $OfferSummary, $mat)) { $TotalNew = strip_tags($mat[0]); } if (eregi($Parse_TotalUsed, $OfferSummary, $mat)) { $TotalUsed = strip_tags($mat[0]); } } $OurPrice_tiny = ""; $OurPrice = ""; $discount = ""; $discount_simple_tiny = ""; $discount_simple_medium_tiny = ""; if (eregi($Parse_Price, $item_line, $mat)) { $Price = $mat[0]; if (eregi($Parse_FormattedPrice, $Price, $mat)) { $OurPrice = strip_tags($mat[0]); $OurPrice_simple = ereg_replace("\\$", "", $OurPrice); $OurPrice_simple = ereg_replace(",", "", $OurPrice_simple); $OurPrice_name = "Price:"; $OurPrice_tiny = "$OurPrice"; $OurPrice = "US$OurPrice"; } #print "$OurPrice_simple > 0 and $ListPrice_simple > $OurPrice_simple "; if ($OurPrice_simple > 0 && $ListPrice_simple > $OurPrice_simple) { #print "$OurPrice > 0 and $ListPrice > $OurPrice "; $dif_simple = $ListPrice_simple - $OurPrice_simple; $discount = number_format(($ListPrice_simple - $OurPrice_simple)*100/$ListPrice_simple); #$discount_only = "$OurPrice ($discount% off)"; $discount_simple_tiny = "
    ($discount% off)"; $discount_simple_medium_tiny = "($discount% off)"; #$discount_tiny = "US\$$dif_simple ($discount%)"; $discount = "US\$$dif_simple ($discount%)"; $discount_name = "You Save:"; $ListPrice = "US$ListPrice"; #print "-- $discount -- "; } elseif ($ListPrice) { $ListPrice = "US$ListPrice"; } } elseif($LowestNewPrice) { $OurPrice_tiny = $LowestNewPrice_tiny; } elseif($ListPrice) { $OurPrice_tiny = $ListPrice_tiny; } if ($ff_mode == "books" or $ff_mode == "classical" or $ff_mode == "music" or $ff_mode == "dvd" or $ff_mode == "vhs") { if (eregi($Parse_Manufacturer, $item_line, $mat)) { $Manufacturer = strip_tags($mat[0]); } } $ProductDescription = ""; if (preg_match_all($Parse_ProductDescription, $item_line, $mat_auth)) { $num_auth = count($mat_auth[0]); for($x_au=0;$x_au<$num_auth;$x_au++) { $Des = $mat_auth[0][$x_au]; if (eregi($Parse_Source, $Des, $mat)) { $Source = strip_tags($mat[0]); } if (eregi($Parse_Content, $Des, $mat)) { $Content = strip_tags($mat[0]); } $Des_1 = "$Source

    $Content

    "; $no = $x_au + 1; $ProductDescription = $ProductDescription.$Des_1; #if ($x_au < $num_auth - 1) #{ #$ProductDescription = $ProductDescription."


    "; #} } } if (eregi($Parse_Media, $item_line, $mat)) { $Media = strip_tags($mat[0]); } if (eregi($Parse_Isbn, $item_line, $mat)) { $Isbn = strip_tags($mat[0]); } if (eregi($Parse_Availability, $item_line, $mat)) { $Availability = strip_tags($mat[0]); } if (eregi($Parse_SalesRank, $item_line, $mat)) { $SalesRank = strip_tags($mat[0]); } if (eregi($Parse_BrowseList, $item_line, $mat)) { $BrowseList = $mat[0]; #print "author -- $Authors \n"; $BrowseList_1 = ""; #print "$Parse_Author aaaaaaaaaaaaaaa-author\n"; preg_match_all($Parse_BrowseNode, $BrowseList, $mat_auth); $num_auth = count($mat_auth[0]); #print "$num_auth bbbbbbbb \n"; for($x_au=0;$x_au<$num_auth;$x_au++) { $BrowseNode= strip_tags($mat_auth[0][$x_au]); $BrowseNode = format($BrowseNode); $BrowseNode_q = rawurlencode($BrowseNode); $BrowseNode = "$BrowseNode"; $BrowseList_1 = $BrowseList_1.$BrowseNode.""; #print "author_1 $Authors_1 \n
    "; } } if (eregi($Parse_NumMedia, $item_line, $mat)) { $NumMedia = strip_tags($mat[0]); } if (eregi($Parse_CustomerReviews, $item_line, $mat)) { $CustomerReviews = $mat[0]; if (eregi($Parse_AvgCustomerRating, $CustomerReviews, $mat_a)) { $AvgCustomerRating = strip_tags($mat_a[0]); } $Reviews_1 = $AvgCustomerRating.""; if (eregi($Parse_TotalCustomerReviews, $CustomerReviews, $mat_a)) { $TotalCustomerReviews = strip_tags($mat_a[0]); } $Reviews_1 = $AvgCustomerRating.""; preg_match_all($Parse_Review, $CustomerReviews, $mat_auth); $num_auth = count($mat_auth[0]); #print "$num_auth \n"; for($x_au=0;$x_au<$num_auth;$x_au++) { $Review = $mat_auth[0][$x_au]; if (eregi($Parse_Rating, $Review, $mat_c)) { $Rating = strip_tags($mat_c[0]); } if (eregi($Parse_Summary, $Review, $mat_c)) { $Summary = strip_tags($mat_c[0]); } if (eregi($Parse_Comment, $Review, $mat_c)) { $Comment = strip_tags($mat_c[0]); } $Reviews_1 = $Reviews_1."$Rating$Summary$Comment"; } } $SimilarProducts_1 = ""; $SimilarProducts_name = ""; $sim_num_auth = 0; if (eregi($Parse_SimilarProducts, $item_line, $mat)) { $SimilarProducts = $mat[0]; #print "author -- $Authors \n"; #print "$Parse_Author aaaaaaaaaaaaaaa-author\n"; preg_match_all($Parse_SimilarProduct, $SimilarProducts, $mat_auth); $sim_num_auth = count($mat_auth[0]); #print "$num_auth bbbbbbbb \n"; for($x_au=0;$x_au<$sim_num_auth;$x_au++) { $Sim = $mat_auth[0][$x_au]; if (eregi($Parse_ProductName, $Sim, $mat_c)) { $Sim_Tit = strip_tags($mat_c[0]); } if (eregi($Parse_Asin_1, $Sim, $mat_c)) { $Sim_Asin = strip_tags($mat_c[0]); } $x_xx = $x_au + 1; $SimilarProducts_1 = $SimilarProducts_1.$Sim_Asin.","; $SimilarProducts_name = $SimilarProducts_name."
    $x_xx. $Sim_Tit "; #print "author_1 $Authors_1 \n
    "; } } $ListmaniaLists_1 = ""; $sim_num_auth = 0; #print "
    lllllllllllllllllllll $Parse_ListmaniaLists $ListmaniaLists"; if (eregi($Parse_ListmaniaLists, $item_line, $mat)) { $ListmaniaLists_1 = "

    Favourite Lists: "; $ListmaniaLists = $mat[0]; preg_match_all($Parse_ListmaniaList, $ListmaniaLists, $mat_auth); $sim_num_auth = count($mat_auth[0]); #print "
    llllllllll Parse_ListmaniaList $Parse_ListmaniaList $sim_num_auth $mat_auth[0][0]"; #print "$num_auth bbbbbbbb \n"; for($x_au=0;$x_au<$sim_num_auth;$x_au++) { $Sim = $mat_auth[0][$x_au]; if (eregi($Parse_ListName, $Sim, $mat_c)) { $Sim_Tit = strip_tags($mat_c[0]); } if (eregi($Parse_ListId, $Sim, $mat_c)) { $Sim_Asin = strip_tags($mat_c[0]); } $x_xx = $x_au + 1; $listmanialist = ""; $listmanialist_url = rawurlencode($Sim_Asin); $listmanialist_name_url = rawurlencode($Sim_Tit); $ListmaniaLists_1 .= "\n
    $x_xx. $Sim_Tit."; } } #print "$count$Asin$Catalog$Authors_1$ProductName$ReleaseDate$Manufacturer$ImageUrlSmall$ImageUrlMedium$ImageUrlLarge$ListPrice$OurPrice$BrowseList_1$Media$Isbn$Availability$SalesRank$NumMedia$Reviews_1$AvgCustomerRating$SimilarProducts_1$Description\n"; $url = $add_line_main.$Asin.$add_line_back; $url_de = $add_line_de.$Asin.$add_line_back_de; $url_fr = $add_line_fr.$Asin.$add_line_back_fr; $url_ca = $add_line_ca.$Asin.$add_line_back_ca; $url_uk = $add_line_uk.$Asin.$add_line_back_uk; $url_jp = $add_line_jp.$Asin.$add_line_back_jp; $ProductName_short_simple_url = "$ProductName_short_simple"; $image_url = ""; if (!$simple_list) { $im_small_only = "\n"; $im_medium_only = "\n"; } else { $im_small_only = "\n"; $im_medium_only = "\n"; $im_large_only = "\n"; } $im_small = ""; $im_med = ""; $im_larg = ""; $im_asin = ""; if ($photo_asin) { $im_type = $im_asin; } elseif($image_size == "small") { $im_type = $im_small; } elseif($image_size == "medium") { $im_type = $im_med; } elseif($image_size == "large") { $im_type = $im_larg; } $x_plus = $x + 1; #if ($ImageUrlSmall) #{ $im_total .= "\n

"; $im_medium_total .= "\n"; #$im_large_total .= "
$im_small_only "; $im_large_total .= "\n$im_large_only  "; #} #else #{ #$im_total .= ""; #$im_medium_total .= " "; #} $im_total .= "\n\n\n"; $im_medium_total .= "\n\n\n
$im_medium_only
 $ProductName_short_simple_url
$OurPrice_tiny $discount_simple_tiny
$OurPrice_tiny $discount_simple_medium_tiny
$ProductName_short_simple_url
$OurPrice_tiny $discount_simple_medium_tiny
$ProductName_short_simple_url
"; if ($x == 4) { $im_total .= ""; $im_medium_total .= ""; } ######################################################################## if ($simple_list != "on") #extra########################## { $html_med .= "\n\n
\n\n"; #width=\"590\" width=\"110\" $html_med .= "\n$item_count. $ProductName
\n"; $l = strlen($Authors_1); if (($Authors_1 != "")&&($l > 4)) { $authors = split("", $Authors_1); #print DOG "
"; $new_auth = count($authors); $author_count = 0; $author_small = "$by_name  "; $author = ""; for($x_au=0;$x_au<$new_auth;$x_au++) { $auth = "$authors[$x_au]"; if (strlen($auth) > 2) { if ($x_au< $new_auth - 2) { $auth .= ", "; } $author .= "$auth"; $author_small .= "$auth
"; } } #print "author = $author \n"; $html_med .= "\n$by_name $author
\n"; } $director = ""; $l = strlen($Directors_1); if (($Directors_1 != "")&&($l > 4)) { $directors = split("", $Directors_1); #print DOG "
"; $new_auth = count($directors); for($x_au=0;$x_au<$new_auth;$x_au++) { $auth = "$directors[$x_au]"; if (strlen($auth) > 2) { if ($x_au< $new_auth - 2) { $auth .= ", "; } $director .= "$auth"; } } $html_med .= "\nDirector: $director
\n"; } $html_med .= "\n$im_type"; $html_med .= "\n
"; if ($OurPrice or $ListPrice) { if ($OurPrice) { $OurPrice .= "
"; $OurPrice_name .= "
"; } if ($ListPrice) { $ListPrice .= "
"; $ListPrice_name .= "
"; } $html_med .= "\n\n"; $html_med .= "\n
$ListPrice_name$OurPrice_name$discount_name$ListPrice$OurPrice$discount
"; } ########################availability not acurate, so comments out (7/21/2003) #if ($Availability) #{ #$html_med .= "Availability: $Availability
"; #} if ($Media) { $html_med .= "\nCategory: $Media"; } elseif($ProductGroup) { $html_med .= "Product: $ProductGroup
"; } if ($Brand) { $html_med .= "\nBrand: $Brand
"; } if ($Department) { $html_med .= "\nDepartment: $Department
"; } if ($ReleaseDate) { $html_med .= "\n ($ReleaseDate)
"; } elseif($Media) { $html_med .= "
"; } if ($ff_mode == "books" or $ff_mode == "classical" or $ff_mode == "music" or $ff_mode == "dvd" or $ff_mode == "vhs") { if ($Manufacturer) { $html_med .= "\nPublisher: $Manufacturer
"; } } if ($Isbn) { $html_med .= "ISBN: $Isbn
"; } elseif ($Asin) { $asin_url = ""; #$html_med .= "ASIN:$asin_url $Asin
"; $html_med .= "ASIN: $Asin
"; } if ($SalesRank) { $html_med .= "Sales Rank: $SalesRank
"; } if ($LowestNewPrice or $LowestUsedPrice) { if ($LowestNewPrice) { $html_med .= "Lowest New Price: $LowestNewPrice "; #if ($TotalNew) #{ #$html_med .= " ($TotalNew New Items)"; #} } if ($LowestUsedPrice) { $html_med .= "
Lowest Used Price: $LowestUsedPrice "; if ($TotalUsed) { $html_med .= " ($TotalUsed Used Items)"; } } $html_med .= "
"; } $html_med .= "\nCanada | "; $html_med .= "United Kingdom | "; $html_med .= "Germany | "; $html_med .= " France |"; $html_med .= " Japan"; $html_med .= "\n

"; $save_isbn = $file_desc_dir.$Asin; #print $save_isbn."-----\n"; if ($ProductDescription) { $ProductDescription = format_1($ProductDescription); $description = "\n$ProductDescription"; if (strlen($description) > 70) { $html_med .= "\n$description"; $html_med .= "\n ... Read more
"; } } elseif (file_exists($save_isbn)) { $desc = file("$save_isbn"); $description = $desc[0]; #print $description."aaaaa"; #$description = ereg_replace(".+", "", $description); #description = ereg_replace("", "&&&&", $description); #description = ereg_replace("", "@@@@", $description); #$description = strip_tags($description); #$description = ereg_replace("@@@@", ":
", $description); #$description = ereg_replace("&&&&", "

", $description); $description = eregi_replace("
", "&&&&", $description); $description = eregi_replace("

", "@@@@", $description); $description = strip_tags($description); $description = ereg_replace("@@@@", "

", $description); $description = ereg_replace("&&&&", "
", $description); $description = eregi_replace("\.\.\.", "", $description); $description = eregi_replace("read more", "", $description); $description = ereg_replace("Book Description", "", $description); $description = "\nDescription

$description"; #$description = ereg_replace("Amazon.com", "", $description); $description = eregi_replace("


", "

", $description); #$description = eregi_replace("&.+;", "", $description); $description = eregi_replace("

", "
", $description); $description = eregi_replace("
$", "", $description); $description = eregi_replace("

$", "", $description); $description = eregi_replace("
\s$", "", $description); $description = eregi_replace("

\n$", "", $description); $description = eregi_replace("
$", "", $description); $description = eregi_replace("


", "

", $description); #$description = eregi_replace("st&.+;", "", $description); if (strlen($description) > 70) { $html_med .= "$description"; $html_med .= "\n ... Read more
"; } } $feature = ""; $l = strlen($Features_1); if (($Features_1 != "")&&($l > 4)) { $features = split("", $Features_1); #print DOG "
"; $new_auth = count($features); #$feature = "

$font_face Features$font_face_1

    "; for($x_au=0;$x_au<$new_auth;$x_au++) { $auth = "$features[$x_au]"; if (strlen($auth) > 2) { $feature .= "
  • $auth"; } } $html_med .= "\n

    Features:

      $feature
    "; } #print "review = $review"; if (strlen($Reviews_1) > 5 && ($review == "on")) { $html_med .= "\n\n\n\n\n\n\n

    Customer Reviews
    "; if ($AvgCustomerRating) { #print @new[19]."\n"; $star_int = number_format($AvgCustomerRating); $star_dec = $AvgCustomerRating - $star_int; if ($star_dec < 0.25) { $star_dec = 0; } elseif ($star_dec < 0.75) { $star_dec = 0.5; } else { $star_dec = 1; } $rating = $star_int + $star_dec; $rating = sprintf("%.1f", $rating); #$rating =~ s/\./-/; $rating = ereg_replace("\.","-",$rating); if (($with_star) and $rating != "0-0") { $star_image = "\n\n\n\"@new[19] "; $html_med .= "\n
    Average Customer Review: $star_image Based on $TotalCustomerReviews reviews."; } } $reviews = split("", $Reviews_1); $l = count($reviews); for($x_au=0;$x_au<$l;$x_au++) { $revw = $reviews[$x_au]; { if (strlen($revw) > 10) { $each_review = split("", $revw); $rating = $each_review[0]; $summary = $each_review[1]; $comment = $each_review[2]; $comment = format_1($comment); $rating = sprintf("%.1f", $rating); $rating = ereg_replace("\.","-",$rating); #print $rating."\n"; if (($with_star) and $rating != "0-0") { $star_image = "\"$rating "; $html_med .= "

    $star_image"; } else { $html_med .= "

    "; } $html_med .= "\n$summary
    $comment"; } } } if ($l > 2) { $review_link = $base_file."?&mode=review&search=$Asin&total_item=$TotalCustomerReviews&productname=$productName_q"; $html_med .= "\n... Read more
    "; } } $similarproduct = ""; $l = strlen($SimilarProducts_1); if (($SimilarProducts_1 != "")&&($l > 4)) { $similarproduct_q = rawurlencode($SimilarProducts_1); $sim_num_auth = $sim_num_auth - 1; $html_med .= "\n
    Similar Items: $SimilarProducts_name."; } $html_med .= $ListmaniaLists_1; $browseList = ""; $l = strlen($BrowseList_1); if (($BrowseList_1 != "")&&($l > 4)) { $productName_q = rawurlencode($ProductName); $browseLists = split("", $BrowseList_1); #print DOG "
    "; $new_auth = count($browseLists); for($x_au=0;$x_au<$new_auth;$x_au++) { $auth = "$browseLists[$x_au]"; if (strlen($auth) > 2) { if ($x_au< $new_auth - 2) { $auth .= ","; } $browseList .= " $auth"; } } $similarproduct_q = rawurlencode($similarproduct); $new_auth_1 = $new_auth - 1; $html_med .= "\n
    Subjects: $browseList"; } $html_med .= "\n


"; } #extra################################ } } $html_small = "\n
\n$im_total\n

"; $html_medium = "\n
\n$im_medium_total\n

"; $html_large = "\n
$im_large_total

"; if ($num > 0) { print "

"; if (!$photo_asin) { if ($image_size == "small") # { print $html_small; } elseif ($image_size == "medium") { print $html_medium; print "
"; } elseif ($image_size == "large") { if ($simple_list) { print $html_large; } else { print $html_small; } } } if ($simple_list != "on") { print $html_med; } print "
"; } #if ($image_size == "medium") #{ #print "\n
Click any image to see the details about the item
$im_total_med
"; #} if ($page == 1) { return $TotalResults; } else { return $num; } } ?> "; $font_face_1 = ""; $font_face_2 = ""; $font_size = "3"; print "\ne99 Store - "; if ($search and $searchtype != "asin" and $searchtype != "list") { print "Search: $subject - $search $searchtitle"; } elseif ($searchtype == "asin") { print "Search: $subject - Items similar to \"$productname\""; } elseif ($searchtype == "list") { print "Search: $subject - \"$productname\" - Favorite Lists"; } else { print "Browse: $subject $node_desc "; } print ' '; print "
 "; $click_image = ""; if (!$photo_asin && $image_size != "large") { #$click_image = "click image to enlarge"; } $browse_main = ""; #if ($mode != "office-products") #{ #$browse_main = "Browse: $subject (Main Menu)"; #} print " e99 Store Help
$click_image
"; print "
print "
Store Home "; if ($mode != "office-products") { if ($search and $searchtype != "asin" and $searchtype != "list") { print " Search: $subject - $search $searchtitle"; } elseif ($searchtype == "asin") { print " Search: $subject - Items similar to \"$productname\""; } elseif ($searchtype == "list") { print " Search: $subject - \"$productname\" - Favorite Lists"; } elseif(!$photo_asin) { print " Browse:   $subject $node_desc "; } else { print " $subjectt"; } } else { print " Search: $subject"; } # print "Search UK | Germany Sites
"; #print "
$font_size_1 Choose small image size (40 x 60) or simple list if you have a slow connection
"; $my_count = 0; if ($mode == "books") { #print "

The server for searching books is temporarily down.
Please try later! You may search other subjects,
or use the following list to browse books.
"; } } function print_form($type, $mode, $search, $page, $image_size, $review, $total_page, $subject, $search_cgi_name, $simple_list, $sort, $searchtype) { #print "
sssssssssssssssssssssssssssssssssssssssssss $search "; #print "kkkkkkkkkkkkkkkkkkkkkk $search_cgi_name aaaaa"; #print $total_page."aaaaaaaaaaa\n"; $bgcolor = "#FFFFFF"; $font_color = "#000000"; $link = "#003399"; $alink = "#ff9933"; $vlink = "#996633"; $font_text = "#000000"; $font_face = ""; $font_face_1 = ""; $font_face_2 = ""; $font_size = "3"; print "

"; if ($type) { #print ""; #print "Advanced Search:"; } print "
"; print "
"; print ""; if ($searchtype == "asin" or $searchtype == "list") { $search = ""; } #else #{ #$search_qq = $search; #} #print "$searchtype = $search_qq"; print "";; #print $Length."----------"; if ($type) { print "\n
$font_face_1 Review"; print " Image only"; print " Results 
"; } if (!$type) { #print "Advanced
"; print "
Image Size:   Small  Medium   "; if ($image_size == "large") { print "checked"; } #print ">Large"; } else { print "
Image SizeSML"; } #write_page_line("foot", $p, $loglength, $num_rec, $base_file); #####################only for sports ################################### #&print_next_list; print ""; #if ($type) #{ print "
"; #} print "
"; } function write_page_line($page_count, $mode, $search, $image_size, $review, $total_page, $total_item, $search_cgi_name, $simple_list, $sort, $node, $node_name) { #$font_face_1 = ""; #print "----------------------------- page $search_cgi_name "; #my $type = @_[0]; #my $page_count = @_[1]; $search = rawurlencode($search); $page_digit = 2; $page_dif = 2; $num_rec = $total_page * 10; $last_page = number_format($total_item/$num_rec, 0, "", ""); #$last_page = number_format($total_item/$num_rec); if ($last_page < $total_item/$num_rec) { $last_page++; } #print $last_page; $page_1 = $page_count - 1; $page_p = $page_count + 1; $lnumber = $page_1*$num_rec; $lnumber++; $tnumber = $page_count*$num_rec; $add_image = ""; $color_h_f = ""; $base_file = "$search_cgi_name"; $base_url_simple = "Simple List\n"; $base_url_full = "Full List\n"; print "
"; #print "

Result Item:          "; if ($tnumber <= $total_item) { print $lnumber."-".$tnumber." of $total_item Results \n"; } else { print $lnumber."-".$total_item." of $total_item Results \n"; } #print "
Page:           "; if ($page_count > 1) { print "      Previous    \n"; } else { #print "      Page:      "; } $page_add = 1; if ($page_count - $page_digit > $page_dif) { $page_add = $page_count - $page_digit; print "  First\n"; $page_add_half = number_format(($page_count - $page_digit)/2, 0, "", ""); print "<\n"; } $t = 1; $last_print_page = $last_page; if ($last_page - $page_count - $page_digit > $page_dif) { $last_print_page = $page_count + $page_digit; } if ($page_count > 1) { while($t <= $total_item && $page_add <= $last_print_page) { #print "t = $t, total_item = $total_item, page_add = $page_add last = $last_print_page"; $t = $page_add*$num_rec; if ($page_add != $page_count) { print "$page_add\n"; } else { print "$page_add\n"; } if ($page_add < 10) { print " "; } $page_add += 1; } if ($last_page - $page_count - $page_digit > $page_dif) { $last_page_add_half = $page_count + $page_digit + number_format(($last_page - $page_count - $page_digit)/2, 0, "", ""); print ">\n"; print "Last\n"; } } if ($tnumber < $total_item) { print "       Next\n"; } print "$write_head_2

"; } function print_next_list($file_next_old, $file_url_dir, $mode) { global $SCRIPT_NAME; global $image_size; global $review; global $total_page; global $simple_list; $search_cgi_name = "$SCRIPT_NAME"; #$font_face_1 = ""; if(file_exists($file_next_old)) { $next_old_info = file("$file_next_old"); #print "print next list $next_old_info $my_n, $mmm, $nnn, \n"; $next_list = split("\|", $next_old_info[0]); $next_list_count = count($next_list); $next_html_list = ""; #print "------- $next_list_count"; if ($next_list_count > 1) { print "\n
\n"; $count = 0; $Length = count($next_list) - 1; $halflength = ($Length + $Length%2)/2; while (list ($key, $t) = each ($next_list)) { $key_index = split("\@", $t); #$node_no = $key_index[0]; #$head_title = $key_index[1]; #added 4/24/2004 for online-store $node_no = $key_index[1]; $head_title = $key_index[0]; $count++; #$file_name_url = $file_url_dir."$node_no/index.html"; $head_title_1 = rawurlencode($head_title); $file_name_url = $search_cgi_name."?mode=$mode&node=$node_no&node_name=$head_title_1&simple_list=$simple_list&image_size=$image_size&review=$review&total_page=$total_page"; $line = "
  • ".$head_title."\n"; #print $line." ".$Length."\n"; if ($count <= $Length) { if ($count <= $halflength) { print $line; } if ($count == $halflength + 1) { print "
  • \n"; } if ($count >= $halflength + 1) { print $line; } } } print "\n

    \n"; } } } function format($line) { $array_line = split(" ", $line); $new_auth = count($array_line); $whole_line = ""; for($x_au=0;$x_au<$new_auth;$x_au++) { $auth = "$array_line[$x_au]"; if ($auth) { $whole_line .= "$auth "; } } $whole_line = ereg_replace(" $", "", $whole_line); return $whole_line; } function format_1($line) { $line = eregi_replace("<", "<", $line); $line = eregi_replace(">",">",$line); $line = eregi_replace("&#160;&#8211;&#160;", " - ", $line); return $line; } ?>