$shipAPI->setMaxServiceLength($code, trim($dim[0])); $shipAPI->setMaxServiceWidth($code, trim($dim[1])); $shipAPI->setMaxServiceHeight($code, trim($dim[2])); } //************************************************************ // Flag Carrier for Flat Rate Box Qualification: OPTIONAL // Item Dimensions are required // AuctionInc will price service at the better of the // flat (if item/s fit) or calcluated rate // USPS (Priority Mail (boxes, envelopes), Express Mail (envelopes) // -- valid values: PKG / ENV / ALL // FEDEX (International Priority (boxes) // -- valid values: PKG // (typically fed in from your seller account configuration) //************************************************************ $shipAPI->setFlatRatePackaging("USPS", 'PKG'); //************************************************************ // Example Items // (typically fed in from cart) //************************************************************ //************************************************************ // Create an array of items to rate //************************************************************ $items = array(); //************************************************************ // Test Item 1 (calculated shipping example) //************************************************************ $item = array(); $item["CalcMethod"] = "C"; $item["refCode"] = "test_item_1"; $item["quantity"] = 1;