well, lyte uses the wordpress is_ssl() function, so if wordpress doesn’t know it’s on https then lyte doesn’t either. you can try a code snippet like this one to hack your way around that;
add_filter('lyte_settings','lyte_https');
function lyte_https($in) {
$in['scheme']="https://";
return $in;
}
hope this helps,
frank
Thanks for answer! But not helped, i edit code in plugin to
$lyteSettings['scheme'] = "https" ;
I deactivated and activated plugin after edit. But it not helped too.
can you share a URL where I can see what is going wrong @alex1305?
hmm, the code I gave earlier was wrong (sorry bout that), should be:
add_filter('lyte_settings','lyte_https');
function lyte_https($in) {
$in['scheme']="https";
return $in;
}
can you change that + clear Lyte’s cache?
ok;
* can you make sure wp-youtube-lyte.php is back to it’s original state (you made a change there, right?)
* can you change the video on that testpage, or add another one?
frank
I deleted then installed plugin to be sure all by default and changed video to new one. But it not helped. Maybe i should change in DB options of plugin?
OK, the links in the noscript tags are not correctly HTTPS, so that works. now for the thumbnail URL, that is fetched from the YouTube API, I’ll have to chech under which conditions they are returned with HTTP vs HTTPS, I’ll report back here when I know more 🙂
OK, lets try enforcing HTTPS on youtube thumbnails this way;
add_filter('lyte_match_thumburl','https_thumburl');
function https_thumburl($thumb) {
return str_replace("http://","https://",$thumb);
}
Its working! You are really awesome! Big thanks. Autoptimize awesome plugin too. Using it and loving it.
great! have fun @alex1305 🙂
Looks like on mobiles not working:).
I tryed to resolve by this code
add_filter('lyte_do_mobile','lyte_on_mobile',10,0);
function lyte_on_mobile(){
return true;
}
but it not helped.
-
This reply was modified 6 years, 10 months ago by alex1305.
well, before playing with code; can you describe what is not working, what do you see?
Wow, crtr+shft+m allow to inspect in chrome mobile version. Problem was not in your plugin. I am sorry. All resolved!:))))