Home / Forums / WoodMart support forum / fix erors from validator.w3.org
Home › Forums › WoodMart support forum › fix erors from validator.w3.org
fix erors from validator.w3.org
- This topic has 40 replies, 2 voices, and was last updated 3 years, 11 months ago by
Artem Temos.
-
AuthorPosts
-
November 17, 2021 at 1:27 pm #332553

Artem TemosKeymasterCould you please clarify where exactly do you see these errors on your website?
November 25, 2021 at 8:16 pm #334651
bigdropParticipantHi,
There is this part of the code that causes the error.
.menu-item-480 .wd-design-sized {min-height: 100px; width: 750px; } .menu-item-382 .wd-design-sized {min-height: 100px; width: 750px; } .menu-item-479 .wd-design-sized {min-height: 100px; width: 750px; } .menu-item-485 .wd-design-sized {min-height: 100px; width: 850px; } .menu-item-383 .wd-design-sized {min-height: 100px; width: 920px; } .menu-item-489 .wd-design-sized {min-height: 100px; width: 550px; } .menu-item-491 .wd-design-sized {min-height: 100px; width: 750px; }November 26, 2021 at 7:32 am #334743
Artem TemosKeymasterHello,
Yes, you are right. We will review this CSS in our next theme update and try to fix.
Kind Regards
November 26, 2021 at 7:47 am #334747
bigdropParticipantPlease also help me fix the bellow error.
November 26, 2021 at 8:05 am #334754
Artem TemosKeymasterIt has been fixed already. We just didn’t upload the fix on our demo.
November 26, 2021 at 9:23 am #334779
bigdropParticipantIs there a documentation for how to create this section?
If I import this section to my theme it shows errors.November 26, 2021 at 9:44 am #334788
Artem TemosKeymasterWe are sorry for the inconvenience. This particular fix will be included in our 6.3 update. Try to add the following PHP code snippet to the child theme functions.php file to fix this now
function woodmart_get_gradient_css( $gradient_attr ) { $gradient_css = explode( '|', $gradient_attr ); $gradient_css[1] = str_replace( array( 'left', 'top', 'right', 'bottom' ), array( 'to left', 'to top', 'to right', 'to bottom' ), $gradient_css[1] ); $result = 'background-image:-webkit-' . $gradient_css[1] . ';'; $result .= 'background-image:' . $gradient_css[1] . ';'; return $result; }November 26, 2021 at 10:30 am #334812
bigdropParticipantThat code fix the issue on validator but brakes the website.
November 26, 2021 at 12:04 pm #334851
Artem TemosKeymasterTry to replace your code with the following one
function woodmart_get_gradient_css( $gradient_attr ) { $gradient_css = explode( '|', $gradient_attr ); $css = $gradient_css[1]; $webkit_css = $gradient_css[1]; if ( strstr( $css, 'left' ) ) { $css = str_replace( 'left', 'to right', $gradient_css[1] ); } elseif ( strstr( $css, 'right' ) ) { $css = str_replace( 'right', 'to left', $gradient_css[1] ); } elseif ( strstr( $css, 'top' ) ) { $css = str_replace( 'top', 'to bottom', $gradient_css[1] ); } elseif ( strstr( $css, 'bottom' ) ) { $css = str_replace( 'bottom', 'to top', $gradient_css[1] ); } $result = 'background-image:-webkit-' . $webkit_css . ';'; $result .= 'background-image:' . $css . ';'; return $result; }November 26, 2021 at 12:28 pm #334864
bigdropParticipantThat worked!
Thank you!!!
November 26, 2021 at 12:59 pm #334884
Artem TemosKeymasterYou are welcome!
-
AuthorPosts
The topic ‘fix erors from validator.w3.org’ is closed to new replies.
- You must be logged in to create new topics. Login / Register