Advanced search  

News:

cpg1.5.46 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter recently discovered vulnerabilities. It is important that all users who run version cpg1.5.44 or older update to this latest version as soon as possible.
[more]

Pages: 1 ... 4 5 6 7 [8]   Go Down

Author Topic: Remote videos for cpg1.5.x  (Read 109904 times)

0 Members and 1 Guest are viewing this topic.

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15369
Re: Remote videos for cpg1.5.x
« Reply #140 on: March 11, 2015, 08:48:12 pm »

I noticed on my private gallery that all YouTube videos stopped to work. I guess you're facing the same problem, but I don't know what you mean with "redirect" in your explanation.

I just had a look at the embed code YouTube currently provides. It obviously changed to iframe. I'll perform some tests as soon as possible.
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15369
Re: Remote videos for cpg1.5.x
« Reply #141 on: March 11, 2015, 09:02:14 pm »

Version 1.10 (attached to initial post) should fix the YouTube issues.
Logged

SFdrifter

  • Coppermine newbie
  • Offline Offline
  • Posts: 1
Re: Remote videos for cpg1.5.x
« Reply #142 on: March 11, 2015, 10:34:08 pm »

Wow!  Thanks for the quick turnaround...works fine!
Logged

kylemj

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: Remote videos for cpg1.5.x
« Reply #143 on: August 02, 2015, 07:17:41 pm »

i've tried to figure out the code to embed
Code: [Select]
<iframe src="http://vk.com/video_ext.php?oid=164681391&id=162151261&hash=45dcf38e51031b2f" width="607" height="360" frameborder="0"></iframe>but every method i tried brings up  Error: invalid video id

Any ideas?
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15369
Re: Remote videos for cpg1.5.x
« Reply #144 on: August 04, 2015, 08:21:13 pm »

Please post more details. What exactly have you tried?
Logged

kylemj

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: Re: Remote videos for cpg1.5.x
« Reply #145 on: August 06, 2015, 08:55:04 pm »

Please post more details. What exactly have you tried?

I didn't keep all the tests but this was the last one i tried, I don't know coding and tried to manipulate existing ones but it didn't work as the VK embed code uses 3 different IDs

Code: [Select]


        case 'vk':

            $params = array(

                'search_pattern' => '/http:\/\/(?:www\.)?vk\.com\/\?video_ext.php?oid=([A-Za-z0-9]+)&id=([A-Za-z0-9]+)&hash=([A-Za-z0-9]+)/',

                'default_width'  => 640,

                'default_height' => 480,

                'player'         => 'http://vk.com/video_ext.php?oid={MATCH_1}&id={MATCH_2}&hash={MATCH_3}',

                'player_height'  => 0,

            );

            return remote_videos_html_replace($params, $pic_html);

        break;



/*

        case '':

            $params = array(

                'search_pattern' => '',

                'default_width'  => ,

                'default_height' => ,

                'player'         => '{MATCH_1}',

                'player_height'  => ,

            );

            return remote_videos_html_replace($params, $pic_html);

        break;

This is the embed code VK gives
Code: [Select]
<iframe src="http://vk.com/video_ext.php?oid=164681391&id=162151261&hash=45dcf38e51031b2f" width="607" height="360" frameborder="0"></iframe>So theoretically just need to know how to get the oid, id and hash values
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15369
Re: Remote videos for cpg1.5.x
« Reply #146 on: August 07, 2015, 01:15:27 pm »

Code: [Select]
'search_pattern' => '/http:\/\/(?:www\.)?vk\.com\/video_ext\.php\?oid=([A-Za-z0-9]+)&id=([A-Za-z0-9]+)&hash=([A-Za-z0-9]+)/',removes the invalid video ID message.

Unfortunately the vk.com player needs some more parameters to play the video:
Code: [Select]
<param name="flashvars" value="uid=164681391&amp;vid=162151261&amp;oid=164681391&amp;host=http://cs505420v4.vk.me/&amp;vtag=3db79b5d6d&amp;ltag=l_6b169856&amp;vkid=162151261&amp;md_title=%26lt%3Biframe+src%3D%22http%3A%2F%2Fvk.com%2Fvideo_ext.php%3Foid%3D7324586%26id%3D162001297%26hash%3Db7d57fd756ecf0d3%26sd%22+width%3D%26quot&amp;md_author=Elena+Rotsel&amp;author_id=164681391&amp;author_href=/id164681391&amp;hd=0&amp;no_flv=1&amp;hd_def=0&amp;dbg_on=0&amp;t=0&amp;duration=63&amp;thumb=http://cs505420.vk.me/u164681391/video/l_6b169856.jpg&amp;hash=6b3a8670eb0ed9db33fef5cd5dc3487f&amp;hash2=45dcf38e51031b2f&amp;angle=0&amp;img_angle=0&amp;repeat=0&amp;show_ads_preroll=0&amp;show_ads_postroll=0&amp;show_ads_overlay=0&amp;legal_owner=0&amp;eid1=0&amp;slot=0&amp;g=0&amp;a=0&amp;puid34=0&amp;water_mark=&amp;can_rotate=1&amp;c3=&amp;no_adfox=1&amp;ads_preview=0&amp;puid4=0&amp;url240=http://cs505420v4.vk.me/u164681391/videos/3db79b5d6d.240.mp4?extra=D0j3UO6n8dPwDgaNZXS5TbpsaynlgivH2y_L8viVqgfY7xW98I-99CNw08vomo0qwM7NyMTi3mmG4EjeM-J4qNC_IdjPOFI&amp;jpg=http://cs505420.vk.me/u164681391/video/l_6b169856.jpg&amp;ip_subm=1&amp;video_ext=1&amp;is_yandex=0&apm;&amp;is_vk=1&amp;is_ext=1&amp;referrer=&amp;lang_add=Add+to+My+Videos&amp;lang_added=Video+added+to+My+Videos&amp;lang_share=Share&amp;lang_like=Like&amp;lang_subscribe=Subscribe&amp;lang_subscribed=You+have+subscribed&amp;lang_volume_on=Unmute&amp;lang_volume_off=Mute&amp;lang_volume=Volume&amp;lang_hdsd=Change+Video+Quality&amp;lang_open_popup=Expand&amp;lang_fullscreen=Full+Screen&amp;lang_window=Minimize&amp;lang_rotate=Rotate&amp;lang_ads_link=Advertiser%27s+Site&amp;lang_ads=Ads&amp;lang_ads_skip=Skip+ad&amp;lang_next=Next+video&amp;lang_replay=Replay&amp;lang_next_cancel=Cancel&amp;lang_ads_skip_time=Skip+ads+in+%7Btime%7D&amp;lang_report_problem=Report+a+problem..&amp;video_play_hd=Watch+in+HD&amp;video_stop_loading=Stop+Download&amp;video_player_version=VK+Video+Player&amp;goto_orig_video=Go+to+Video&amp;video_get_video_code=Copy+video+code&amp;video_load_error=The+video+has+not+uploaded+yet+or+the+server+is+not+available&amp;video_get_current_url=Copy+frame+link"></param>

so the video player cannot be embedded directly in Coppermine, but needs an iframe. Please have a look how it has been solved for vine.
Logged

kylemj

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: Remote videos for cpg1.5.x
« Reply #147 on: August 09, 2015, 05:24:55 pm »

After many days of clueless testing i have got it to work  ;D

ok and to share

find
Code: [Select]
$params['player'] = str_replace("{MATCH_2}", $video_id[2], $params['player']);

and below add
Code: [Select]
$params['player'] = str_replace("{MATCH_3}", $video_id[3], $params['player']);

find
Code: [Select]
$params['extra_params'] = str_replace("{MATCH_2}", $video_id[2], $params['extra_params']);
and below add
Code: [Select]
$params['extra_params'] = str_replace("{MATCH_3}", $video_id[3], $params['extra_params']);
after the last case (eg. vine after break; add
Code: [Select]
        case 'vk':

            $params = array(

'search_pattern' => '/http:\/\/(?:www\.)?vk\.com\/video_ext\.php\?oid=([A-Za-z0-9]+)&id=([A-Za-z0-9]+)&hash=([A-Za-z0-9]+)/',

                'default_width'  => 660,

                'default_height' => 415,

                'player'         => 'http://vk.com/video?act=get_swf&oid={MATCH_1}&vid={MATCH_2}&embed_hash={MATCH_3}',
Logged

kylemj

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 25
Re: Remote videos for cpg1.5.x
« Reply #148 on: August 09, 2015, 10:35:56 pm »

You'll need to take the url out of the embed code and to save the text file extension as .vk
Logged

chant_s

  • Coppermine newbie
  • Offline Offline
  • Posts: 6
Re: Remote videos for cpg1.5.x
« Reply #149 on: November 15, 2015, 06:42:55 pm »

With this plugin you can 'upload' videos from Youtube and other video file hosters to your website.

Please find the button for the config page on the plugin manager. There you can enable/disable the different video hosters.

Usage:
1. Create a text file and insert the permalink or url from the browser address bar (e.g. http://www.youtube.com/watch?v=6B26asyGKDo)
2. Rename the text file to <filename>.<provider> (e.g. my_video.youtube)
3. Upload the text file to your Coppermine gallery (use the upload form or the batch-add feature)
4. Optional: upload a thumbnail for your video by using this plugin

Download: http://sourceforge.net/projects/coppermine/files/Plugins/1.5.x/cpg1.5.x_plugin_remote_videos_v1.9.zip/download

Ive uploaded the folder to the gallery directory, as well as the txt file, but this plugin doenst show in plugin directory? nor does the video work
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15369
Re: Remote videos for cpg1.5.x
« Reply #150 on: November 15, 2015, 06:55:01 pm »

Please read the docs how to install Coppermine plugins.
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15369
Re: Remote videos for cpg1.5.x
« Reply #151 on: March 23, 2016, 12:25:24 pm »

Version 1.11 (attached to initial post) adds general iframe support. Additionally the deprecated <object> embed was replaced by an iframe for YouTube.
Logged
Pages: 1 ... 4 5 6 7 [8]   Go Up
 

Page created in 0.028 seconds with 23 queries.