| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
w3c validation question | |||
|
|
Thread Tools | Search this Thread |
#1
|
|||||||
|
|||||||
w3c validation question
I get this error from w3c validator
Quote:
I have had this error before on other sites too but am not sure how to make it valid. Anyone know?
__________________
www.uscandleco.com - X-Cart Version 4.7.11 Gold Plus php7.3 mods: reCaptcha running on UNIX www.keystonecandle.com X-Cart Gold Plus - Version 4.7.11 php7.2 mods: reCaptcha cdseo pro running on UNIX |
|||||||
#2
|
|||||||
|
|||||||
Re: w3c validation question
I also have an error caused by this line of code in /common_files/customer/main/product_prices.tpl
Code:
the validator doesn't like that Code:
Code:
it validates fine but I don't know if that will break functionality or not. Anyone know if changing that is wrong?
__________________
www.uscandleco.com - X-Cart Version 4.7.11 Gold Plus php7.3 mods: reCaptcha running on UNIX www.keystonecandle.com X-Cart Gold Plus - Version 4.7.11 php7.2 mods: reCaptcha cdseo pro running on UNIX |
|||||||
#3
|
|||||||
|
|||||||
Re: w3c validation question
Styles need to go in the head tag - can't be in the body.
The unique ID one is one you are going to have to live with - but it doesn't affect display so just ignore it.
__________________
Padraic Ryan Ryan Design Studio Professional E-Commerce Development |
|||||||
#4
|
|||||||
|
|||||||
Re: w3c validation question
So if the styles were part of a mod and they had them in the .tpl should I just cut them out and past them in with my main.css file?
__________________
www.uscandleco.com - X-Cart Version 4.7.11 Gold Plus php7.3 mods: reCaptcha running on UNIX www.keystonecandle.com X-Cart Gold Plus - Version 4.7.11 php7.2 mods: reCaptcha cdseo pro running on UNIX |
|||||||
#5
|
|||||||||
|
|||||||||
Re: w3c validation question
Yep, you can consolidate the styles if that part of the validation is really important.
If the same id is appearing more than once it is probably a bug and may need to be reported. |
|||||||||
#6
|
|||||||
|
|||||||
Re: w3c validation question
I'm not sure it is a bug because I think the multiple id's only shows up because I am using BCSE Easy Variant View mod which takes all the variants and lays them out in a table so customers can see all the products at once without having to click on each one from a drop down list. When the mod loops through all the variants it repeats the code from /common_files/customer/main/product_prices.tpl for each one. That is where the id is repeated. Not sure really how to fix that though. Like balinor said, I may just have to ignore it. I like having valid code though so I may start twitching once in while.
__________________
www.uscandleco.com - X-Cart Version 4.7.11 Gold Plus php7.3 mods: reCaptcha running on UNIX www.keystonecandle.com X-Cart Gold Plus - Version 4.7.11 php7.2 mods: reCaptcha cdseo pro running on UNIX |
|||||||
#7
|
|||||||||
|
|||||||||
Re: w3c validation question
You can even change it to "class" or use the loop to add a number to it "wl-prices-1(2,3...)". This id is probably used by default cart js code to find/change wholesale pricing but since you have this bcse mod and you have the id repeating the cart will not know where to apply changes if needed anyway so that id is useless. If you don't have wholesale pricing it is not important anyway, if you have wholesale pricing they will not work as intended with the id repeating.
__________________
Steve Stoyanov CFLSystems.com Web Development |
|||||||||
#8
|
|||||||
|
|||||||
Re: w3c validation question
Yes, I usually take the css files for the mods and combine them with the main CSS file or put them in the head where they belong.
__________________
Padraic Ryan Ryan Design Studio Professional E-Commerce Development |
|||||||
#9
|
|||||||
|
|||||||
Re: w3c validation question
I'm attempting to set up the counter to add a number to the end of id="wl-prices" like Steve suggested. I'm not sure how to do it correctly. Here is what the set up is.
from /common_files/customer/main/bcse_evv.tpl: Code:
from customer/main/product_prices.tpl: Code:
I'm thinking that I need to initiate a counter maybe here? (not quite sure of correct bracketing, etc) /common_files/customer/main/bcse_evv.tpl: Code:
then append the number to wl-prices like this somehow in customer/main/product_prices.tpl: Code:
Am I even close?
__________________
www.uscandleco.com - X-Cart Version 4.7.11 Gold Plus php7.3 mods: reCaptcha running on UNIX www.keystonecandle.com X-Cart Gold Plus - Version 4.7.11 php7.2 mods: reCaptcha cdseo pro running on UNIX |
|||||||
#10
|
|||||||||
|
|||||||||
Re: w3c validation question
Just change it to class and make your life easier Either way the XC builtin code will not work for wl-prices
__________________
Steve Stoyanov CFLSystems.com Web Development |
|||||||||
|
|||
X-Cart forums © 2001-2020
|