Checkout_shipping page text change

Open to all! Ask other shopowners for help.
Post Reply
14Steve14
Senior Contributor
Posts: 923
Joined: Fri Oct 25, 2019 7:01 pm
Phoenix Version: v1.0.9.1
Has thanked: 17 times
Been thanked: 103 times

Checkout_shipping page text change

Post by 14Steve14 »

Test store using 1.0.8.20 PHP8

I use raiwa's ship in cart addon but I don't think this affects it as the code seems to be in a core code module.

On the checkout shipping page the shipping methods show with a weight under the method which only shows as a figure and no weight type. (See left image below).

To remove that figure I have remove the following bit of code from the templates/default/includes/pages/checkout_shipping.php. The list now looks like the righthand image. I will copy this to the override folder when everything is working as I would like.

Code: Select all

          if (!Text::is_empty($method['title'])) {
            echo '<div class="form-text">' . $method['title'] . '</div>';
          }
Is that the correct way of removing that code as I cannot see a setting anywhere to not show shipping weight.

Also, should it show something after the weight figures like Kg or grammes or lbs or what ever weight the store owner uses.


Join The Code Co-op to get access to your library in the Code Co-op Forum
User avatar
burt
Core Team
Posts: 4551
Joined: Tue Oct 29, 2019 9:37 am
Phoenix Version: v1.1.0.8
Has thanked: 252 times
Been thanked: 412 times

Re: Checkout_shipping page text change

Post by burt »

In the module file of each, something like;

Code: Select all

'title' => BLAH_BLAH_TEXT_WAY . ' ' . $shipping_weight,
to

Code: Select all

'title' => BLAH_BLAH_TEXT_WAY,
I am not here to build for you.
I am here to build with you. Let's help each other.
14Steve14
Senior Contributor
Posts: 923
Joined: Fri Oct 25, 2019 7:01 pm
Phoenix Version: v1.0.9.1
Has thanked: 17 times
Been thanked: 103 times

Re: Checkout_shipping page text change

Post by 14Steve14 »

Gary @burt Thanks for your help with this. I am getting there with the shipping modules you created.

The weight also shows in the sub totals on the page as well, so how to remove it from there.
checkout_shipping_2.png
User avatar
burt
Core Team
Posts: 4551
Joined: Tue Oct 29, 2019 9:37 am
Phoenix Version: v1.1.0.8
Has thanked: 252 times
Been thanked: 412 times

Re: Checkout_shipping page text change

Post by burt »

I'm not sure on that, is that an addon's output or is that core code output ?

I know I did something in order_total for 1.0.8.21, but that was a simple removal of a colon which wouldn't have anything to do with this, I think;
https://github.com/CE-PhoenixCart/Phoen ... 0357ebbed0


Join The Code Co-op to get access to your library in the Code Co-op Forum
Post Reply