the CSS that styles the player damienov , leaving it unstyled?
yes leaving it unstyled, I know I can overwrite that with !important but it can cause several issues.
so perhaps adding an option to disable it or adding a parameter on the shortcode to disable the inline styling
OK, you can use the lyte_css filter to change (or clear) the CSS, e.g.;
add_filter( 'lyte_css', '__return_empty_string' );
hope this helps 🙂
frank
Excellent! thank you for the quick response
perhaps you should add this in a documentation 🙂
maybe, but guess this is way too complex for 99,99% of users who do not mind the CSS-in-JS anyway 😉
hmm after trying it the inline styling still persist
<div class="lyte-wrapper" title="Playlist: #MyPlaylist" style="width:560px;max-width: 100%;margin:5px auto;">
ah, that one is generated by PHP code and can be different depending on settings, but if you insist you can use the lyte_match_postparse_template filter to change anything in the LYTE output? 😉
I see
a future feature request then :p
perhaps adding an option or a shorcode parameter, something like
line 352 wp-lyte-youtube-php
} elseif ($lyte_noInline == false) {
$wrapper="<div class=\"lyte-wrapper".$lyteSettings['ratioClass']."\"".$_this_title_tag.">";
}
-
This reply was modified 5 years ago by
Damienov.
-
This reply was modified 5 years ago by
Damienov.
why not use lyte_match_postparse_template to replace the style-attribute? 🙂
honestly? I’ve tried it
can’t seem to make it work lol
eh.. I’m crappy at php 🙂
finally got this working lol
add_filter('lyte_match_postparse_template','no_inline');
function no_inline($x) {
$x = str_replace('style="width:560px;max-width: 100%;margin:5px auto;"','',$x);
return $x;
}
I hope this is the right way