| ||||||||||
![]() |
Shopping cart software Solutions for online shops and malls | |||||||||
![]() |
![]() |
|
X-Cart Home | ![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
variants - call for price | |||
![]() |
|
|
Thread Tools | Search this Thread |
#1
|
|||||||
|
|||||||
![]() hi,
in 4.4.5 how would i make certain variants display call for price instead of the variant price (set to 0 at the moment) im guessing its a javascript thing, as the price automatically changes with the variants dropdown? thanks
__________________
Version 4.4.2 |
|||||||
#2
|
|||||||||
|
|||||||||
![]() Hi Jon. I looked into this for you and found that the template that controls this JS is: **YOUR-SKIN-DIR**/modules/Product_Options/func.js
Around line 187 find this: /* Update price */ if (document.getElementById('product_price')) document.getElementById('product_price').innerHTML = price; And change it to: /* Update price */ if (document.getElementById('product_price')) if (price == '0'){ price = "Call"; document.getElementById('product_price').innerHTML = price; } else { document.getElementById('product_price').innerHTML = price_format(Math.max(price, 0)); } Now this isn't going to handle everything for you, this is just an example of where to get started, and how to go about making the change that you want. There may be other ways, this was the first solution I came across.
__________________
Mike White - Now Accepting new clients and projects! Work with the best, get a US based development team for just $125 an hour. Call 1-502-773-6454, email mike at babymonkeystudios.com, or skype b8bym0nkey XcartGuru X-cart Tutorials | X-cart 5 Tutorials Check out the responsive template for X-cart. |
|||||||||
|
#3
|
|||||||
|
|||||||
![]() thanks for that, it was easier than i thought.
i changed it a bit to... if (price == 0) { $('.currency').hide(); $('.callforprice').show(); } else { $('.currency').show(); $('.callforprice').hide(); document.getElementById('product_price').innerHTML = price_format(Math.max(price, 0)); } so it hides the currency symbol and shows a span with my call for price message
__________________
Version 4.4.2 |
|||||||
|
#4
|
|||||||||
|
|||||||||
![]() Great. Thanks for posting your final solution. It sure helps the forum be the type of resource that it should be when you do that. Glad it was an easy fix.
__________________
Mike White - Now Accepting new clients and projects! Work with the best, get a US based development team for just $125 an hour. Call 1-502-773-6454, email mike at babymonkeystudios.com, or skype b8bym0nkey XcartGuru X-cart Tutorials | X-cart 5 Tutorials Check out the responsive template for X-cart. |
|||||||||
#5
|
|||||||
|
|||||||
![]() I need a 'call for price' on a variant. To be more clear, I currently have it working for the price on the variant but I don't know how to disable the add-to-cart button in product_details.tpl since the price is set with a javascript call (check_options in func.js). Once the function returns I need to know if the price is zero or have a variable I can check. Any ideas? Maybe I'm doing this the wrong way.
Thanks,
__________________
X-cart Ver: 4.7.10 (Linux/Apache) XCartMods Ultra Template BCSE Authorize DPM Module CDSEO 2.2.0 CDSEO Pro Admin |
|||||||
#6
|
|||||||||
|
|||||||||
![]() IMHO call for price feature shouldn't be used in an online store. Just think about you ask a potential customer to call you just for finding a price. I am wondering how many will do a phone call. Personally I won't do that. Same thing for asking login to see prices.
__________________
X-Cart Next: Business 5.2 (learning and testing) X-Cart Classic: Gold and Gold Plus 4.7 Lots of Modules and Customizations OS in use: Red Hat Enterprise, Fedora, CentOS, Debian, Ubuntu, Linux Mint, Kali Linux Ideas for Server configuration (basicaly): Nginx/Pound (reverse proxy), Apache/Nginx (webserver), Squid/Varnish (cache server), HHVM or (PHP-FPM + PHP 5.6 + opcache), MariaDB/Percona MySQL Server, Redis (storing sessions) You can catch my ideas here: http://ideas.x-cart.com |
|||||||||
#7
|
|||||||
|
|||||||
![]() Thanks. Actually, I have the same opinion. But in this case, it's expensive gold jewelry and the supplier is constantly changing the price.
__________________
X-cart Ver: 4.7.10 (Linux/Apache) XCartMods Ultra Template BCSE Authorize DPM Module CDSEO 2.2.0 CDSEO Pro Admin |
|||||||
#8
|
|||||||||
|
|||||||||
![]() As an advice you should show a price, but ask the customer for confirmation because of a strong reason. From the very beginning you give him an idea about how much costs, then it needs a confirmation (it could be +/-). This will help you not losing customers who are stressed by calling for prices. You can also monitor your pages in real time and check how many calls you get for the most visited products.
__________________
X-Cart Next: Business 5.2 (learning and testing) X-Cart Classic: Gold and Gold Plus 4.7 Lots of Modules and Customizations OS in use: Red Hat Enterprise, Fedora, CentOS, Debian, Ubuntu, Linux Mint, Kali Linux Ideas for Server configuration (basicaly): Nginx/Pound (reverse proxy), Apache/Nginx (webserver), Squid/Varnish (cache server), HHVM or (PHP-FPM + PHP 5.6 + opcache), MariaDB/Percona MySQL Server, Redis (storing sessions) You can catch my ideas here: http://ideas.x-cart.com |
|||||||||
|
|||
X-Cart forums © 2001-2020
|