asked 2 years ago

I have a small problem with DW Magz v1.0.6 … the (DW) Latest Videos piece on the frontpage is stripping HTTPS from links to youtube video thumbnails and is loading insecure http thumbnails instead.
The thumbnails on the side vertical playlist on the front page (ul class=”latest-playlist”) are generated as insecure http links, and this breaks the overall HTTPS integrity of the site. The videos themselves are referenced via proper https links, but the thumbnails are not.
Any suggestion where should i start poking to fix the http thumbnails?

3 Answers
answered 2 years ago

update:  i was right, the youtube thumbnails are hard-coded into the theme code.
I changed them to https and the problem went away. I also noticed that Vimeo thumbnails have the same problem… hard-coded insecure thumbnails
in dw-magz\inc\init.php at line 233:

function dw_magz_video_thumbnail( $video_url ) {
    $image_url = parse_url( $video_url );
    if ( '' == $image_url['host'] || '' == $image_url['host'] ) {
        $array = explode( '&', $image_url['query'] );
        return '' . substr( $array[0], 2 ) . '/hqdefault.jpg';
    } else if ( '' == $image_url['host'] || '' == $image_url['host'] ) {
        $hash = unserialize( file_get_contents( '' . substr( $image_url['path'], 1 ) . '.php' ) );
        return $hash[0]['thumbnail_small'];


answered 2 years ago

Yes, I sent and notified into our technical team about this issue, we will check and resolve it in the next version. 

answered 4 months ago

problem: my DW Magz got updated to version 1.0,7 and the video thumbnails are broken again.
It tries yet again to load plain old HTTP when the website is HTTPS.

replied 4 months ago

note: fixed it as before, by editing that file again.

Powered by DW Question & Answer Pro