Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

USPS select shipping servces ONLY


zaurm

Recommended Posts

ok got a little problem here:

 

my working usps.php file: http://www.zadva.com/usps.txt

 

but i get all of the services:

 

Global Express Guaranteed $100

Global Express Guaranteed Non-Document Rectangular $100

Global Express Guaranteed Non-Document Non-Rectangular $100

USPS GXG Envelopes $100

Express Mail International (EMS) $32

Express Mail International (EMS) Flat-Rate Envelope $30

Priority Mail International $26

Priority Mail International Flat-Rate Envelope $16

Priority Mail International Flat-Rate Box $43

Priority Mail International Large Flat-Rate Box $54

First Class Mail International Large Envelope $12

First Class Mail International Package

 

 

but i need to narrow it down to:

Global Express Guaranteed $100

Express Mail International (EMS) $32

Priority Mail International $26

 

 

 

 

any idea how??

 

thanks in advance!

 

also if you can please give me the update usps.php with my inquary

Link to comment
Share on other sites

ok got a little problem here:

 

my working usps.php file: http://www.zadva.com/usps.txt

 

but i get all of the services:

 

Global Express Guaranteed $100

Global Express Guaranteed Non-Document Rectangular $100

Global Express Guaranteed Non-Document Non-Rectangular $100

USPS GXG Envelopes $100

Express Mail International (EMS) $32

Express Mail International (EMS) Flat-Rate Envelope $30

Priority Mail International $26

Priority Mail International Flat-Rate Envelope $16

Priority Mail International Flat-Rate Box $43

Priority Mail International Large Flat-Rate Box $54

First Class Mail International Large Envelope $12

First Class Mail International Package

 

 

but i need to narrow it down to:

Global Express Guaranteed $100

Express Mail International (EMS) $32

Priority Mail International $26

 

 

 

 

any idea how??

 

thanks in advance!

 

also if you can please give me the update usps.php with my inquary

 

I hope this contribution that I am giving will not only help you but others that have been searching for weeks like myself on how to fix this problem. I am very new with setting up an osCommerce store and have learned a lot from the questions and answers in this Community Support so this is the least that I can do. Please make copies of your files when changing anything. This is what I do before I fix anything or take anyone's advise. Below is the fix that I use to narrow do my "USPS INTL OPTIONS",

 

 

Change this:

 

if (isset($this->service) && ($service != $this->service) ) {

continue;

}

 

$rates[] = array($service => $postage);

 

 

 

 

To This:

 

 

if (isset($this->service) && ($service != $this->service) ) {

continue;

}

 

if(!in_array($service, $this->intl_types)) {

continue;

}

 

$rates[] = array($service => $postage);

 

 

Then look at the example below // out what you don't need.

 

 

$this->intl_types = array(

//'Global Express' => 'Global Express Guaranteed',

//'Global Express Non-Doc Rect' => 'Global Express Guaranteed Non-Document Rectangular',

// 'Global Express Non-Doc Non-Rect' => 'Global Express Guaranteed Non-Document Non-Rectangular',

// 'Global Express Envelopes' => 'USPS GXG Envelopes',

//'Express Mail Int' => 'Express Mail International (EMS)',

//'Express Mail Int Flat Rate Env' => 'Express Mail International (EMS) Flat-Rate Envelope',

//'Priority Mail International' => 'Priority Mail International',

'Priority Mail Int Flat Rate Env' => 'Priority Mail International Flat-Rate Envelope',

'Priority Mail Int Flat Rate Box' => 'Priority Mail International Flat-Rate Box',

'Priority Mail Int Flat Rate Lrg Box' => 'Priority Mail International Flat Rate Large Box',

'First Class Mail Int Lrg Env' => 'First Class Mail International Large Envelope',

'First Class Mail Int Package' => 'First Class Mail International Package',

'First Class Mail Int Letters' => 'First Class Mail International Letters',

'First Class Mail Int Flats' => 'First Class Mail International Flats',

'First Class Mail Int Parcels' => 'First Class Mail International Parcels'

);

Link to comment
Share on other sites

veronica, thanks! I really appreciate your response! it worked! Thank you VERY MUCH!!!

 

I also have 2 more question for you, if u dont mind : rolleyes.gif

1) at the whatsnew box on the main page, theres a short description of the product, which is ugly since it gives no useful info at all. so isit possible to remove that ugly beginning of the product description? also is it possible to add custom "short" description

2) is it possible to have 2 store logos (one image banner on the left and the other banner - store desctiption image on the right)???

Link to comment
Share on other sites

veronica, thanks! I really appreciate your response! it worked! Thank you VERY MUCH!!!

 

I also have 2 more question for you, if u dont mind : rolleyes.gif

1) at the whatsnew box on the main page, theres a short description of the product, which is ugly since it gives no useful info at all. so isit possible to remove that ugly beginning of the product description? also is it possible to add custom "short" description

2) is it possible to have 2 store logos (one image banner on the left and the other banner - store desctiption image on the right)???

 

 

For The What's New box in the column:

 

If you want to change any box heading you can do that at catalog/include/language/english.php

 

define('BOX_HEADING_WHATS_NEW', 'New Products Added'); (example to change What's New heading)

 

 

To remove the box

 

The what's new box on the index.php page can be removed by commenting out the code below. This will let you bring the what's new back should you change your mind by just un-commenting the line.

 

Solution

 

In the catalog/index.php file you will see this line about line 343:

 

<td><br><?php include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></td>

 

 

Comment this out with:

 

<td><br><?php // include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></td>

 

NOTE: Commenting out this code removes the what's new box on the index.php page only.

 

For Title Page:

 

If you want to change osCommerce template default title look:

 

catalog/includes/languages/english/index.php...(some people has public_html/language/english/index.php)

 

<?php

/*

$Id: index.php 1739 2007-12-20 00:52:16Z hpdl $

 

osCommerce, Open Source E-Commerce Solutions

<?php

/*

$Id: index.php 1739 2007-12-20 00:52:16Z hpdl $

 

osCommerce, Open Source E-Commerce Solutions

http://www.oscommerce.com

 

Copyright © 2007 osCommerce

 

Released under the GNU General Public License

*/

 

define('TEXT_MAIN', 'The is where you write your description about your store');

 

The Banner I don't know much about.

 

Please make copy of these files before you change anything.

 

There are lots of things I don't know about osCommerce because I am learning as I go, I have made a lot of mistakes, crash a lot of files, but was able to fix it because I made back-up files. I do a lot of experiment with my files; have no idea what I was doing; if it does not work I replace with the copy that I make. There are lots of information in osCommerce and people do work together to give the answers. One of the things I do as a new learner is go to Google or Yahoo and put in search words of what I am looking for, example 'how do I remove box column in osCommerce' and it will take me right there where people are looking for the same answer. Hope this help you and good luck!

Link to comment
Share on other sites

  • 3 weeks later...
I hope this contribution that I am giving will not only help you but others that have been searching for weeks like myself on how to fix this problem. I am very new with setting up an osCommerce store and have learned a lot from the questions and answers in this Community Support so this is the least that I can do. Please make copies of your files when changing anything. This is what I do before I fix anything or take anyone's advise. Below is the fix that I use to narrow do my "USPS INTL OPTIONS",

 

 

Change this:

 

if (isset($this->service) && ($service != $this->service) ) {

continue;

}

 

$rates[] = array($service => $postage);

 

 

 

What folder/file is this code in?

 

Cordially,

hwkd

 

 

 

 

To This:

 

 

if (isset($this->service) && ($service != $this->service) ) {

continue;

}

 

if(!in_array($service, $this->intl_types)) {

continue;

}

 

$rates[] = array($service => $postage);

 

 

Then look at the example below // out what you don't need.

 

 

$this->intl_types = array(

//'Global Express' => 'Global Express Guaranteed',

//'Global Express Non-Doc Rect' => 'Global Express Guaranteed Non-Document Rectangular',

// 'Global Express Non-Doc Non-Rect' => 'Global Express Guaranteed Non-Document Non-Rectangular',

// 'Global Express Envelopes' => 'USPS GXG Envelopes',

//'Express Mail Int' => 'Express Mail International (EMS)',

//'Express Mail Int Flat Rate Env' => 'Express Mail International (EMS) Flat-Rate Envelope',

//'Priority Mail International' => 'Priority Mail International',

'Priority Mail Int Flat Rate Env' => 'Priority Mail International Flat-Rate Envelope',

'Priority Mail Int Flat Rate Box' => 'Priority Mail International Flat-Rate Box',

'Priority Mail Int Flat Rate Lrg Box' => 'Priority Mail International Flat Rate Large Box',

'First Class Mail Int Lrg Env' => 'First Class Mail International Large Envelope',

'First Class Mail Int Package' => 'First Class Mail International Package',

'First Class Mail Int Letters' => 'First Class Mail International Letters',

'First Class Mail Int Flats' => 'First Class Mail International Flats',

'First Class Mail Int Parcels' => 'First Class Mail International Parcels'

);

Link to comment
Share on other sites

I hope this contribution that I am giving will not only help you but others that have been searching for weeks like myself on how to fix this problem. I am very new with setting up an osCommerce store and have learned a lot from the questions and answers in this Community Support so this is the least that I can do. Please make copies of your files when changing anything. This is what I do before I fix anything or take anyone's advise. Below is the fix that I use to narrow do my "USPS INTL OPTIONS",

 

 

Change this:

 

if (isset($this->service) && ($service != $this->service) ) {

continue;

}

 

$rates[] = array($service => $postage);

 

 

 

 

To This:

 

 

if (isset($this->service) && ($service != $this->service) ) {

continue;

}

 

if(!in_array($service, $this->intl_types)) {

continue;

}

 

$rates[] = array($service => $postage);

 

 

Then look at the example below // out what you don't need.

 

 

$this->intl_types = array(

//'Global Express' => 'Global Express Guaranteed',

//'Global Express Non-Doc Rect' => 'Global Express Guaranteed Non-Document Rectangular',

// 'Global Express Non-Doc Non-Rect' => 'Global Express Guaranteed Non-Document Non-Rectangular',

// 'Global Express Envelopes' => 'USPS GXG Envelopes',

//'Express Mail Int' => 'Express Mail International (EMS)',

//'Express Mail Int Flat Rate Env' => 'Express Mail International (EMS) Flat-Rate Envelope',

//'Priority Mail International' => 'Priority Mail International',

'Priority Mail Int Flat Rate Env' => 'Priority Mail International Flat-Rate Envelope',

'Priority Mail Int Flat Rate Box' => 'Priority Mail International Flat-Rate Box',

'Priority Mail Int Flat Rate Lrg Box' => 'Priority Mail International Flat Rate Large Box',

'First Class Mail Int Lrg Env' => 'First Class Mail International Large Envelope',

'First Class Mail Int Package' => 'First Class Mail International Package',

'First Class Mail Int Letters' => 'First Class Mail International Letters',

'First Class Mail Int Flats' => 'First Class Mail International Flats',

'First Class Mail Int Parcels' => 'First Class Mail International Parcels'

);

 

 

 

 

 

 

It is in the public_html/includes/modules/shipping/usps.php

 

Look around line 301 you will find the codes

Good luck!

Link to comment
Share on other sites

I have a similar need. I need to only show standard priority mail for USA, and Priority Mail International for everywhere else. I haven't actually got my USPS module working yet. I'm trying to use the default USPS module, but I heard that it only works in production mode. I'm waiting for USPS to give me the stuff I need for that, but in the meantime I'm trying to figure everything else out.

No Links To My Website Here!

Link to comment
Share on other sites

I have a similar need. I need to only show standard priority mail for USA, and Priority Mail International for everywhere else. I haven't actually got my USPS module working yet. I'm trying to use the default USPS module, but I heard that it only works in production mode. I'm waiting for USPS to give me the stuff I need for that, but in the meantime I'm trying to figure everything else out.

 

Go to public_html/includes/modules/shipping/usps.php...

 

 

For USA Shipping

 

$this->types = array('EXPRESS' => 'Express Mail',

// 'FIRST CLASS' => 'First-Class Mail',

'PRIORITY' => 'Priority Mail',

// 'PARCEL' => 'Parcel Post');

 

 

This is International Shipping

 

Change this:

 

if (isset($this->service) && ($service != $this->service) ) {

continue;

}

 

$rates[] = array($service => $postage);

 

 

To This: (Around Line 301)

 

 

if (isset($this->service) && ($service != $this->service) ) {

continue;

}

 

if(!in_array($service, $this->intl_types)) {

continue;

}

 

$rates[] = array($service => $postage);

 

 

Then look at the example below // out what you don't need.

 

 

$this->intl_types = array(

//'Global Express' => 'Global Express Guaranteed',

//'Global Express Non-Doc Rect' => 'Global Express Guaranteed Non-Document Rectangular',

// 'Global Express Non-Doc Non-Rect' => 'Global Express Guaranteed Non-Document Non-Rectangular',

// 'Global Express Envelopes' => 'USPS GXG Envelopes',

//'Express Mail Int' => 'Express Mail International (EMS)',

//'Express Mail Int Flat Rate Env' => 'Express Mail International (EMS) Flat-Rate Envelope',

'Priority Mail International' => 'Priority Mail International',

//'Priority Mail Int Flat Rate Env' => 'Priority Mail International Flat-Rate Envelope',

//'Priority Mail Int Flat Rate Box' => 'Priority Mail International Flat-Rate Box',

//'Priority Mail Int Flat Rate Lrg Box' => 'Priority Mail International Flat Rate Large Box',

//'First Class Mail Int Lrg Env' => 'First Class Mail International Large Envelope',

//'First Class Mail Int Package' => 'First Class Mail International Package',

//'First Class Mail Int Letters' => 'First Class Mail International Letters',

//'First Class Mail Int Flats' => 'First Class Mail International Flats',

//'First Class Mail Int Parcels' => 'First Class Mail International Parcels'

);

 

 

 

Hope this work for you; let me know.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...