Adrian
asked 5 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?
Thanks

5 Answers
Adrian
answered 5 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 ( 'www.youtube.com' == $image_url['host'] || 'youtube.com' == $image_url['host'] ) {
        $array = explode( '&', $image_url['query'] );
        return 'http://img.youtube.com/vi/' . substr( $array[0], 2 ) . '/hqdefault.jpg';
    } else if ( 'www.vimeo.com' == $image_url['host'] || 'vimeo.com' == $image_url['host'] ) {
        $hash = unserialize( file_get_contents( 'http://vimeo.com/api/v2/video/' . substr( $image_url['path'], 1 ) . '.php' ) );
        return $hash[0]['thumbnail_small'];
    }
}

 

DominicStaff
answered 5 years ago

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

Adrian
answered 4 years 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.

Adrian
replied 4 years ago

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

Adrian
answered 2 years ago

years later: DW Magz .. at version 1.0.9 now, still has the same problem… and the same fix

Dominic Staff
replied 2 years ago

Yes, we are checking and fixing the issue and we will release the next version Today.

DominicStaff
answered 2 years ago

We have updated and released the lastest version, you can check and update the theme now.

Powered by DW Question & Answer Pro