I'm trying to find out where to change the messages that are displayed when no shipping rates are displayed, e.g.

No shipping rates found for your order. Please continue the checkout process.

and

No valid shipping rates found for your order, and we require shipping service selection to complete checkout.') . '
' . t('Please verify you have supplied all required information or contact us to resolve the issue.

I can see the text in commerce_shipping.checkout_pane.inc, but I can't find a way to override these through the Commerce Shipping UI. I also can't find any other issues discussing this. Does such a UI exist?

My use case is - I don't want to ship to Alaska or Hawaii. I'd rather the shipping message advise the customer that this is the case, and not have to have a separate pane at checkout that explains this.

Thanks.

Comments

millionleaves created an issue. See original summary.

googletorp’s picture

Category: Feature request » Support request
Status: Active » Closed (won't fix)

This issue queue is not meant for a place to get help for your project, I would advise you use chanels like the Drupal forums, Drupal answers, IRC etc

scott.browne’s picture

Been digging for this one for a while now and totally taking a ton of time to find. I'm embarrassed to say it but it would have been great if you provided an answer as I'm forced to hack your code as the OP most likely did. This will make updating your code very difficult down the road.

millionleaves’s picture

Thought I would add a solution to this requirement since I had to redo the text on the site that was behind the creation of this issue.

You can add the following code to your settings.php file:

$conf['locale_custom_strings_en'][''] = array(
   'Old string 1'      => 'New string 1',
   'Old string 2'      => 'New string 2',
 );

I have tested this with the shipping messages and it works to replace the default text with the desired text, including HTML if you need it.