Jump to content
LazyCircles

Change Carrier Price/free Shipping Text

Recommended Posts

Hello,

 

I want to change a carrier price option, instead of showing the "price" or "free shipping" I want to add some custom text or make it blank..

 

I'd like to know if it's possible, what is the best way?

 

Thanks!

 

Best Regards

Share this post


Link to post
Share on other sites

location-> translation->chose what you want to change, theme and language

Share this post


Link to post
Share on other sites

location-> translation->chose what you want to change, theme and language

Ok thanks! What if I want one carrier saying "Free shipping" and another one saying "on request" ? I think I can't do it this way

  • Like 1

Share this post


Link to post
Share on other sites

That is more complicated. The simple way to do it is only having that display in order-carriers.tpl, checking which id is currently used in the loop, and displaying what you want for the price. Otherwise it's definitely complex, and you need an insane number of modifications to add other parameters to carriers, and have them display during the checkout

Share this post


Link to post
Share on other sites

That is more complicated. The simple way to do it is only having that display in order-carriers.tpl, checking which id is currently used in the loop, and displaying what you want for the price. Otherwise it's definitely complex, and you need an insane number of modifications to add other parameters to carriers, and have them display during the checkout

 

Hello Nemo1, thanks for the help. I'm having some difficulties understanding where I can get carrier block ID. The only way I can target them is via radio button value.

 

Actually I was modifying the Html field via jQuery but it brings some problems...:

 

-The carriers block only loads after saving address = I have to execute a setTimeout function (i think it is not good method).

 

- If the user doesn't allow geolocation it ignores that code in my javascript :S

 

This is the code i have..

 

$(document).ready(function(){
   $("#opc_guestCheckout").click(function(){
      saveButtonFunction();
   });
});
 
function saveButtonFunction(){
   $("#submitGuestAccount").live("click", function(){
   setTimeout(countryChecker, 1000);
   });
}
 
function countryChecker(){
   if($(".delivery_option_radio [value=86,]").val() == "86,"){
      $(".delivery_option .delivery_option_price").remove();
   }
   else if($(".delivery_option_radio [value=85,]").val() == "85,"){
      $(".delivery_option .delivery_option_price").remove();
   }
}
 
Thanks!
 
Best Regards

Share this post


Link to post
Share on other sites

I did by modifying order-carrier.tpl in the delivery option I did something like this..

 

{elseif $carrier.instance->name == 'Name of carrier you want to add exception'}
{l s='Sob Consulta'}
 
Note: this is only for the front end (thats what is needed), the price is set to "free" in BO.
 
Thanks
Edited by LazyCircles (see edit history)
  • Like 1

Share this post


Link to post
Share on other sites

Where can I find order-carrier.tpl?

Sorry but I don't know where it is.

Share this post


Link to post
Share on other sites
On 6/18/2019 at 12:28 PM, sotirisa said:

Where can I find order-carrier.tpl?

 Sorry but I don't know where it is.

Hi sotirisa, 

Sorry for the late reply, try here: themes/YOUR_THEME/order-carrier.tpl

Share this post


Link to post
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.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  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...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More