USPS

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

matthiasone
Forum Contributor
Posts: 117
Joined: Mon Jul 22, 2002 12:14 pm
Location: Texas, USA
Contact:

Post by matthiasone »

I ended up have to modify that script just a little to make it work.


From this:

Code: Select all

foreach ($svc as $s) { 
        if ($s === 'Parcel') $m = sauship_xmltag('Machinable',0,$machinable,1)."\n"; 
        else $m = '';

to this

Code: Select all

foreach ($svc as $s) { 
        if ($s === 'Parcel') $m = sauship_xmltag('Machinable',0,$machinable,1)."\n"; 
        else $m = sauship_xmltag('Machinable',0,$machinable,1)."\n";
User avatar
Stoker
Forum Regular
Posts: 782
Joined: Thu Jan 23, 2003 9:45 pm
Location: SWNY
Contact:

Post by Stoker »

chad, most important thing is to find out if you have curl installed and working! If not, the UPS will require many changes.. The USPS part can be easily changed to use file() or fopen() instead.

If you have curl, turn debugging on and look at what is produced.. Bothe the UPS and the USPS API gives error messages back if something is wrong...
Post Reply