$count = 0; open(FILE, "herbalarea.pl") || die "I can't open that because: $!\ +n"; while(<FILE>) { chop; @all = split(/\n/); foreach $line (@all) { local($hStoreID, $hStoreName, $hStoreUserName, $hStorePassword, $h +StoreMCRSPassword, $hStoreCity, $hStoreProv, $hStoreAdd, $hStoreAdd2, + $hStorePC, $hStoreCountry, $hStoreEmail, $hStorePhone, $hStoreType, +$hStoreLatitude, $hStoreLongitude, $hStoreFirstName, $hStoreLastName, + $hStoreHPhone, $hStoreCPhone, $hStoreEmail2, $hStoreOwner, $hStoreAd +min, $hStoreAdmin2, $hStoreAdmin3, $hStoreActive, $hStoreWeb, $hStore +Lang, $hStoreDesc, $hStoreShowMap, $hStoreComingSoonText, $hStoreComi +ngSoonTextFrench, $hStoreVanityName, $hStoreWebCreatedDate, $hStoreLa +stLogin, $hStoreLastEnabled, $hStoreManagerEmpID, $hStoreURL) = split +(/ /, $line); $lat2 = $hStoreLatitude; $lon2 = $hStoreLongitude; $lat1 = $lat1a; $lon1 = $lon1a; @L = (deg2rad($lat1), deg2rad(90 - $lon1)); @T = (deg2rad($lat2), deg2rad(90 - $lon2)); $km = great_circle_distance(@L, @T, 6378); if ($km < $distance) { $match = 1; $count ++; $area = "$hStoreName <BR> $hStoreAdd <br> $hStoreCity, $hStorePro +v $hStorePC\n"; $area1 = "$hStoreAdd $hStoreAdd2 $hStoreCity, $hStoreProv $h +StorePC\n"; $area2 = "$hStoreCity, $hStoreProv\n"; print " <table border=0 width=240 height=105 cellpadding=15 cellspacing=0 back +ground=\"http://pagelinx.com/herbalmagic/files/loc_bck.gif\"> <tr> <td style=\"font-size: 11px; color: #5D5D5D;\"> Store # <A HREF=\"javascript:change1('pic1','image$count')\">$area</A> +<BR>\n"; print "<div class=\"book\"> <A HREF=\"http://www.pagelinx.com/herbalmagic/form.php?center=$hStoreN +ame&address=$hStoreAdd&city=$hStoreCity&prov=$hStoreProv\" target=_pa +rent>Book Your Free Consultation</a> - KM $km</div></A></td> </tr> </table> \n"; } } }
In reply to Sort output by pglinx
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |